From c0b2053dd5796404220cd8c954fc8a93785f1584 Mon Sep 17 00:00:00 2001 From: Marcel Werk Date: Fri, 31 Jan 2020 18:26:35 +0100 Subject: [PATCH] Use function_exists to check for disabled functions --- wcfsetup/test.php | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/wcfsetup/test.php b/wcfsetup/test.php index a2bf23784e..394d4d68c5 100644 --- a/wcfsetup/test.php +++ b/wcfsetup/test.php @@ -354,8 +354,7 @@ function checkInstallFile() { } function checkOpcache() { if (extension_loaded('Zend Opcache') && @ini_get('opcache.enable')) { - $disabledFunctions = explode(',', @ini_get('disable_functions')); - if (in_array('opcache_reset', $disabledFunctions) || in_array('opcache_invalidate', $disabledFunctions)) { + if (!function_exists('\opcache_reset') || !function_exists('\opcache_invalidate')) { return false; } } -- 2.20.1