mirror of
https://gerrit.wikimedia.org/r/mediawiki/extensions/AbuseFilter.git
synced 2024-09-24 18:58:17 +00:00
Fix regex error handling by returning immediately if error reporting is disabled.
This commit is contained in:
parent
6678b42d8e
commit
db3c0bbe05
|
@ -1587,6 +1587,7 @@ class AbuseFilterParser {
|
|||
}
|
||||
|
||||
public static function regexErrorHandler( $errno, $errstr, $errfile, $errline, $context ) {
|
||||
if ( error_reporting() == 0 ) { return true; }
|
||||
throw new AFPUserVisibleException( 'regexfailure', $context['pos'],
|
||||
array( $errstr, $context['regex'] ) );
|
||||
return true;
|
||||
|
|
Loading…
Reference in a new issue