From 2169891651aded4defe33a1d08e1b07f79b9f086 Mon Sep 17 00:00:00 2001 From: mattclegg Date: Sat, 18 Apr 2020 18:27:40 +0545 Subject: [PATCH] BUGFIX: Ensure realpath returns a string for stripos [Deprecated] stripos(): Non-string needles will be interpreted as strings in the future. Use an explicit chr() call to preserve the current behavior --- src/Core/Manifest/ModuleManifest.php | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/Core/Manifest/ModuleManifest.php b/src/Core/Manifest/ModuleManifest.php index bcdc68b19..ed05cd3a1 100644 --- a/src/Core/Manifest/ModuleManifest.php +++ b/src/Core/Manifest/ModuleManifest.php @@ -271,7 +271,8 @@ class ModuleManifest $modules = ModuleLoader::inst()->getManifest()->getModules(); foreach ($modules as $module) { // Check if path is in module - if (stripos($path, realpath($module->getPath())) !== 0) { + $realPath = realpath($module->getPath()); + if ($realPath && stripos($path, $realPath) !== 0) { continue; }