Skip to content

Commit 47a1686

Browse files
committed
PHP/RestrictedPHPFunctions: rephrase error message
Follow up on the conversation about this phrasing in #2491 (comment) and #2693 (comment)
1 parent 3c514da commit 47a1686

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

WordPress/Sniffs/PHP/RestrictedPHPFunctionsSniff.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@ public function getGroups() {
3535
return array(
3636
'create_function' => array(
3737
'type' => 'error',
38-
'message' => '%s() is deprecated as of PHP 7.2 and removed in PHP 8.0. Please use declared named or anonymous functions instead.',
38+
'message' => '%s() interally performs an eval(), which makes this a very dangerous function. For this reason, it was deprecated as of PHP 7.2 and removed in PHP 8.0. Please use anonymous functions, or declare a named function instead.',
3939
'functions' => array(
4040
'create_function',
4141
),

0 commit comments

Comments
 (0)