X-Git-Url: https://git.heureux-cyclage.org/?p=lhc%2Fweb%2Fwiklou.git;a=blobdiff_plain;f=includes%2Flibs%2Fobjectcache%2FEmptyBagOStuff.php;h=575bc58746e91a6b5ad2f2a7f833d533a5e3632b;hp=ffe3a4c53e37b567541b0cbcaa0ffbebd47bb2e3;hb=dfec83932fd38a9086eb5a2e212889ad00f35b0e;hpb=b6a1f3bc774d043c69e9ed2875210049cdda9d68 diff --git a/includes/libs/objectcache/EmptyBagOStuff.php b/includes/libs/objectcache/EmptyBagOStuff.php index ffe3a4c53e..575bc58746 100644 --- a/includes/libs/objectcache/EmptyBagOStuff.php +++ b/includes/libs/objectcache/EmptyBagOStuff.php @@ -33,15 +33,15 @@ class EmptyBagOStuff extends BagOStuff { return false; } - public function add( $key, $value, $exp = 0, $flags = 0 ) { + protected function doSet( $key, $value, $exp = 0, $flags = 0 ) { return true; } - public function set( $key, $value, $exp = 0, $flags = 0 ) { + protected function doDelete( $key, $flags = 0 ) { return true; } - public function delete( $key, $flags = 0 ) { + public function add( $key, $value, $exptime = 0, $flags = 0 ) { return true; } @@ -49,6 +49,10 @@ class EmptyBagOStuff extends BagOStuff { return false; } + public function incrWithInit( $key, $ttl, $value = 1, $init = 1 ) { + return false; // faster + } + public function merge( $key, callable $callback, $exptime = 0, $attempts = 10, $flags = 0 ) { return true; // faster }