1
0
mirror of https://github.com/flextype/flextype.git synced 2025-08-08 06:06:45 +02:00

feat(cache): add PHPArray cache driver #557

This commit is contained in:
Awilum
2021-08-01 14:05:19 +03:00
parent 02c057b2a6
commit 24b22693ec

View File

@@ -69,13 +69,15 @@ class Driver implements ExtendedCacheItemPoolInterface, AggregatablePoolInterfac
{
$file_path = $this->getFilePath($item->getKey(), true);
try{
$content = include $file_path;
}catch (PhpfastcacheIOException $e){
return null;
}
$value = null;
return $content;
set_error_handler(static function () {});
$value = include $file_path;
restore_error_handler();
return $value;
}
/**