From 0ed0eea73b6fca0edfcd1af47661a43e7a6e8041 Mon Sep 17 00:00:00 2001 From: AD7six Date: Wed, 5 Nov 2008 19:32:45 +0000 Subject: [PATCH] modifying cache file engine, to match file class changes. git-svn-id: https://svn.cakephp.org/repo/branches/1.2.x.x@7830 3807eeeb-6ff5-0310-8944-8be069107fe0 --- cake/libs/cache/file.php | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/cake/libs/cache/file.php b/cake/libs/cache/file.php index bfc755447..40ec52c27 100644 --- a/cake/libs/cache/file.php +++ b/cake/libs/cache/file.php @@ -243,7 +243,10 @@ class FileEngine extends CacheEngine { */ function __setKey($key) { $this->__File->Folder->cd($this->settings['path']); - $this->__File->name = $key; + if ($key !== $this->__File->name) { + $this->__File->name = $key; + $this->__File->path = null; + } if (!$this->__File->Folder->inPath($this->__File->pwd(), true)) { return false; }