summaryrefslogtreecommitdiff
path: root/modules/rest/helpers
diff options
context:
space:
mode:
authorTim Almdal <tnalmdal@shaw.ca>2010-09-01 23:19:50 -0700
committerTim Almdal <tnalmdal@shaw.ca>2010-09-01 23:19:50 -0700
commit545177c648eb2ce98b3ea35688518b9fc7432957 (patch)
treefebb16f4536b39b1984ee5d58cfabbcf6878aecf /modules/rest/helpers
parent04f6646b0637d9cb221159b4931b184449a4dc1d (diff)
parent70c8572ea1b421458241b9b3b1cc85cb6bf35057 (diff)
Merge branch 'master' of git@github.com:gallery/gallery3
Diffstat (limited to 'modules/rest/helpers')
-rw-r--r--modules/rest/helpers/rest_installer.php4
1 files changed, 3 insertions, 1 deletions
diff --git a/modules/rest/helpers/rest_installer.php b/modules/rest/helpers/rest_installer.php
index c2694a29..3c7fea4b 100644
--- a/modules/rest/helpers/rest_installer.php
+++ b/modules/rest/helpers/rest_installer.php
@@ -35,7 +35,9 @@ class rest_installer {
static function upgrade($version) {
$db = Database::instance();
if ($version == 1) {
- $db->query("RENAME TABLE {user_access_tokens} TO {user_access_keys}");
+ if (in_array("user_access_tokens", Database::instance()->list_tables())) {
+ $db->query("RENAME TABLE {user_access_tokens} TO {user_access_keys}");
+ }
module::set_version("rest", $version = 2);
}