Skip to content

Commit

Permalink
Using ${var} in strings is deprecated, use {$var} instead
Browse files Browse the repository at this point in the history
In php8.2
https://wiki.php.net/rfc/deprecate_dollar_brace_string_interpolation

Change-Id: Ieaf5a620efd04ee46598577a9d1905c62c2b052e
  • Loading branch information
umherirrender committed Nov 30, 2022
1 parent 7106f44 commit fc31270
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/SecurityCheckPlugin.php
Expand Up @@ -590,7 +590,7 @@ public static function parseTaintLine( string $line ): ?array {
$types = '(?P<type>htmlnoent|html|sql|shell|serialize|custom1|'
. 'custom2|code|path|regex|sql_numkey|escaped|none|tainted)';
$prefixes = '(?P<prefix>escapes|onlysafefor|exec)';
$taintExpr = "(?P<taint>(?:${prefixes}_)?$types|array_ok|allow_override)";
$taintExpr = "(?P<taint>(?:{$prefixes}_)?$types|array_ok|allow_override)";

$filteredLine = preg_replace( "/((?:$taintExpr,? *)+)(?: .*)?$/", '$1', $line );
$taints = explode( ',', strtolower( $filteredLine ) );
Expand Down

0 comments on commit fc31270

Please sign in to comment.