Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

Already on GitHub? Sign in to your account

[2.1] [WIP] ZF2-554 Implement XCache storage adapter #2362

Closed
wants to merge 7 commits into
from
@@ -391,7 +391,7 @@ public function optimize()
*/
public function getTotalSpace()
{
- if ($this->totalSpace !== null) {
+ if ($this->totalSpace === null) {
$path = $this->getOptions()->getCacheDir();
ErrorHandler::start();
@@ -400,6 +400,7 @@ public function getTotalSpace()
if ($total === false) {
throw new Exception\RuntimeException("Can't detect total space of '{$path}'", 0, $error);
}
+ $this->totalSpace = $total;
// clean total space buffer on change cache_dir
$events = $this->getEventManager();
@@ -412,7 +413,7 @@ public function getTotalSpace()
$events->detach($handle);
}
};
- $handle = $events->attach($callback);
+ $handle = $events->attach('option', $callback);
}
return $this->totalSpace;
Oops, something went wrong.