Skip to content

Commit

Permalink
Hardcode ENT_QUOTES as int 3 in disallowed-loose-calls.neon config
Browse files Browse the repository at this point in the history
PHPStan 1.10.58 updated nette/di from v3.1.5 to v3.1.10 and possibly that's the reason why ::constant is not accepted anymore.
phpstan/phpstan-src#2907

The config file is tested so even if the value of the constant would change, however unlikely, it would be detected by failing tests.

Close #249
  • Loading branch information
spaze committed Feb 13, 2024
1 parent fe56632 commit 64137f2
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion disallowed-loose-calls.neon
Original file line number Diff line number Diff line change
Expand Up @@ -9,4 +9,4 @@ parameters:
function: 'htmlspecialchars()'
message: 'set the $flags parameter to `ENT_QUOTES` to also convert single quotes to entities to prevent some HTML injection bugs'
allowParamFlagsAnywhere:
2: ::constant(ENT_QUOTES)
2: 3 # ENT_QUOTES

0 comments on commit 64137f2

Please sign in to comment.