From f23f8885624b249d5ec7bb525b9d6b007ab00293 Mon Sep 17 00:00:00 2001 From: David Grudl Date: Mon, 2 Jan 2017 18:15:22 +0100 Subject: [PATCH] presence of cacheStorage is checked only in register(), not in rebuild() --- src/RobotLoader/RobotLoader.php | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/RobotLoader/RobotLoader.php b/src/RobotLoader/RobotLoader.php index 6eec52d..49c48ba 100644 --- a/src/RobotLoader/RobotLoader.php +++ b/src/RobotLoader/RobotLoader.php @@ -143,7 +143,11 @@ public function getIndexedClasses() */ public function rebuild() { - $this->getCache()->save($this->getKey(), Nette\Utils\Callback::closure($this, 'rebuildCallback')); + if ($this->cacheStorage) { + $this->getCache()->save($this->getKey(), Nette\Utils\Callback::closure($this, 'rebuildCallback')); + } else { + $this->rebuildCallback(); + } }