We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 1a1079d commit e0c5155Copy full SHA for e0c5155
src/Symfony/Component/Cache/Traits/ApcuTrait.php
@@ -23,7 +23,13 @@ trait ApcuTrait
23
{
24
public static function isSupported()
25
26
- return function_exists('apcu_fetch') && ini_get('apc.enabled');
+ if ('cli' === PHP_SAPI) {
27
+ $isEnabledIni = ini_get('apc.enable_cli');
28
+ } else {
29
+ $isEnabledIni = ini_get('apc.enabled');
30
+ }
31
+
32
+ return function_exists('apcu_fetch') && $isEnabledIni;
33
}
34
35
private function init($namespace, $defaultLifetime, $version)
0 commit comments