diff options
author | irgsmirx <tobias.ramforth@udo.edu> | 2013-02-11 20:28:36 +0100 |
---|---|---|
committer | irgsmirx <tobias.ramforth@udo.edu> | 2013-02-11 20:28:36 +0100 |
commit | 062befd1fc90b6c9b6ac835a3d4babce6d8f8c81 (patch) | |
tree | 739d129d5df277db31359a18745dfa903aecfd4d /lib | |
parent | ca99ff31dcc48a3eea343ba8020d92f4e3a526c6 (diff) | |
download | nextcloud-server-062befd1fc90b6c9b6ac835a3d4babce6d8f8c81.tar.gz nextcloud-server-062befd1fc90b6c9b6ac835a3d4babce6d8f8c81.zip |
Update lib/files/cache/legacy.php
Fixing a bug that occurs when trying to update a non-existent 'fscache' table in the database - if unfixed upgrading does not succeed.
Unfortunately I could not get a call to PEAR::isError working. That is why I check for the existence of a property present in class MDB2_Error.
Diffstat (limited to 'lib')
-rw-r--r-- | lib/files/cache/legacy.php | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/lib/files/cache/legacy.php b/lib/files/cache/legacy.php index 33d4b8e7c9f..6d1ffa7b40b 100644 --- a/lib/files/cache/legacy.php +++ b/lib/files/cache/legacy.php @@ -51,6 +51,12 @@ class Legacy { $this->cacheHasItems = false; return false; } + + if ($result === false || property_exists($result, 'error_message_prefix')) { + $this->cacheHasItems = false; + return false; + } + $this->cacheHasItems = (bool)$result->fetchRow(); return $this->cacheHasItems; } |