fix cache regex
This commit is contained in:
parent
e2970a4d91
commit
000dca9fc0
|
@ -141,7 +141,7 @@ class Cache
|
||||||
{
|
{
|
||||||
$matches = [];
|
$matches = [];
|
||||||
$c = null;
|
$c = null;
|
||||||
if ($dsn && preg_match("#(.*)://(.*)#", $dsn, $matches) && !isset($_GET['DISABLE_CACHE'])) {
|
if ($dsn && preg_match('<(.*):\/\/(.*)>', $dsn, $matches) && !isset($_GET['DISABLE_CACHE'])) {
|
||||||
if ($matches[1] == "memcached") {
|
if ($matches[1] == "memcached") {
|
||||||
$c = new MemcachedCache($matches[2]);
|
$c = new MemcachedCache($matches[2]);
|
||||||
} elseif ($matches[1] == "apc") {
|
} elseif ($matches[1] == "apc") {
|
||||||
|
|
Loading…
Reference in New Issue