Skip to content

Commit 841cccd

Browse files
authored
Merge pull request #9761 from Alkisum/removed-return-type-false-from-date-and-gmdate
Removed return type false from date and gmdate
2 parents d4c5f85 + 3d122a7 commit 841cccd

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

src/Psalm/Internal/Provider/ReturnTypeProvider/DateReturnTypeProvider.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -64,6 +64,6 @@ public static function getFunctionReturnType(FunctionReturnTypeProviderEvent $ev
6464
return $format_type;
6565
}
6666
}
67-
return Type::combineUnionTypes($format_type, Type::getFalse());
67+
return $format_type;
6868
}
6969
}

tests/FunctionCallTest.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1791,14 +1791,14 @@ function test() : void {
17911791
'$F===' => 'string',
17921792
'$y2===' => 'numeric-string',
17931793
'$F2===' => 'string',
1794-
'$F3===' => 'false|string',
1794+
'$F3===' => 'string',
17951795
'$gm_y===' => 'numeric-string',
17961796
'$gm_ym===' => 'numeric-string',
17971797
'$gm_m===' => 'numeric-string',
17981798
'$gm_F===' => 'string',
17991799
'$gm_y2===' => 'numeric-string',
18001800
'$gm_F2===' => 'string',
1801-
'$gm_F3===' => 'false|string',
1801+
'$gm_F3===' => 'string',
18021802
],
18031803
],
18041804
'sscanfReturnTypeWithTwoParameters' => [

0 commit comments

Comments
 (0)