mirror of
https://github.com/kamilwylegala/cakephp2-php8.git
synced 2025-01-31 09:06:17 +00:00
Adding return false when Memcache is set as the cache engine and the memcache extension is not installed.
git-svn-id: https://svn.cakephp.org/repo/branches/1.2.x.x@4939 3807eeeb-6ff5-0310-8944-8be069107fe0
This commit is contained in:
parent
b3850c56e8
commit
b6fb4d80d0
1 changed files with 3 additions and 0 deletions
3
cake/libs/cache/memcache.php
vendored
3
cake/libs/cache/memcache.php
vendored
|
@ -43,6 +43,9 @@ class MemcacheEngine extends CacheEngine {
|
||||||
* @return boolean True if the engine has been succesfully initialized, false if not
|
* @return boolean True if the engine has been succesfully initialized, false if not
|
||||||
*/
|
*/
|
||||||
function init(&$params) {
|
function init(&$params) {
|
||||||
|
if(!class_exists('Memcache')) {
|
||||||
|
return false;
|
||||||
|
}
|
||||||
$servers = array('127.0.0.1');
|
$servers = array('127.0.0.1');
|
||||||
$compress = false;
|
$compress = false;
|
||||||
extract($params);
|
extract($params);
|
||||||
|
|
Loading…
Add table
Reference in a new issue