Skip to content

Commit

Permalink
🚿 what the fuck phpstan???
Browse files Browse the repository at this point in the history
  • Loading branch information
codemasher committed Aug 4, 2024
1 parent d6effe5 commit a5aa81e
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 1 deletion.
5 changes: 5 additions & 0 deletions phpstan-baseline.neon
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,11 @@ parameters:
count: 1
path: src/DummyStream.php

-
message: "#^Offset 'uri' on array\\{timed_out\\: bool, blocked\\: bool, eof\\: bool, unread_bytes\\: int, stream_type\\: string, wrapper_type\\: string, wrapper_data\\: mixed, mode\\: string, \\.\\.\\.\\} on left side of \\?\\? always exists and is not nullable\\.$#"
count: 1
path: src/HTTPFactory.php

-
message: "#^Property chillerlan\\\\HTTP\\\\Psr7\\\\ServerRequest\\:\\:\\$uploadedFiles \\(array\\{tmp_name\\: array\\<string\\>, size\\: array\\<int\\>, error\\: array\\<int\\>, name\\: array\\<string\\>, type\\: array\\<string\\>\\}\\) does not accept default value of type array\\{\\}\\.$#"
count: 1
Expand Down
1 change: 0 additions & 1 deletion src/HTTPFactory.php
Original file line number Diff line number Diff line change
Expand Up @@ -121,7 +121,6 @@ public static function createStreamFromSource(mixed $source = null):StreamInterf

if($type === 'resource'){
// avoid using php://input and copy over the contents to a new stream
/** @phpstan-ignore-next-line */
if((stream_get_meta_data($source)['uri'] ?? '') === 'php://input'){
$stream = StreamUtil::tryFopen('php://temp', 'r+');

Expand Down

0 comments on commit a5aa81e

Please sign in to comment.