diff --git a/filter.php b/filter.php index e62b81b..19b37c3 100644 --- a/filter.php +++ b/filter.php @@ -178,7 +178,7 @@ protected function is_ws_access() { } // Check rare cases, like webservice/pluginfile.php. - if (strpos($ME, 'webservice/') !== false) { + if (!is_null($ME) && strpos($ME, 'webservice/') !== false) { $token = optional_param('token', '', PARAM_ALPHANUM); if ($token) { return true;