Skip to content

Commit a4d4dd6

Browse files
neilimefabpot
authored andcommitted
chore(HttpFoundation): define phpdoc type for Response "statusTexts"
As `Symfony\Component\HttpFoundation\Response::$statusTexts` is public, it can be used by everyone. Some of us can use type analysis like PSALM or PHPStan... It is always useful, and for some of them mandatory to have a proper array typing to use this variable.
1 parent 658b7a4 commit a4d4dd6

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

Response.php

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -121,6 +121,8 @@ class Response
121121
* (last updated 2021-10-01).
122122
*
123123
* Unless otherwise noted, the status code is defined in RFC2616.
124+
*
125+
* @var array<int, string>
124126
*/
125127
public static array $statusTexts = [
126128
100 => 'Continue',

0 commit comments

Comments
 (0)