Page MenuHomePhabricator

Warning: strpos(): Empty delimiter in /.../AbuseFilter.parser.php on line 1912
Closed, ResolvedPublic


Author: accnospamtom

Warning triggered in our wiki when uploading, moving, deleting a file or deleting a page ...

In this cases, the var $needle isn't defined (I don't know why), so strpos fails.

I manually fixed this warning in our wiki by adding

if (isset($needle)) {

around the foreach-part in at line 1912

Version: master
Severity: normal



Event Timeline

bzimport raised the priority of this task from to Medium.Nov 22 2014, 3:04 AM
bzimport added a project: AbuseFilter.
bzimport set Reference to bz60203.

This looks like it's related to one of your specific filters. What filters are you using?

accnospamtom wrote:

Ohh, I'm such an idiot ... I didn't think of our filters ... ;)

this filter was causing it:

contains_any( lcase ( rmwhitespace (added_lines) ),
) &
article_namespace != 10

Change 108220 had a related patch set uploaded by Jackmcbarn:
Don't pass empty strings to strpos

By the way, the problem happened to you because of the extra comma after the last parameter to contains_any.

accnospamtom wrote:

thank you :)

Change 108220 merged by jenkins-bot:
Don't pass empty strings to strpos