diff options
Diffstat (limited to 'vendor/illuminate/cache/FileStore.php')
| -rwxr-xr-x | vendor/illuminate/cache/FileStore.php | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/vendor/illuminate/cache/FileStore.php b/vendor/illuminate/cache/FileStore.php index f48ebc2b19..228d69976e 100755 --- a/vendor/illuminate/cache/FileStore.php +++ b/vendor/illuminate/cache/FileStore.php @@ -186,7 +186,13 @@ class FileStore implements Store return $this->emptyPayload(); } - $data = unserialize(substr($contents, 10)); + try { + $data = unserialize(substr($contents, 10)); + } catch (Exception $e) { + $this->forget($key); + + return $this->emptyPayload(); + } // Next, we'll extract the number of seconds that are remaining for a cache // so that we can properly retain the time for things like the increment |
