diff options
author | Tim Almdal <tnalmdal@shaw.ca> | 2008-11-08 01:19:03 +0000 |
---|---|---|
committer | Tim Almdal <tnalmdal@shaw.ca> | 2008-11-08 01:19:03 +0000 |
commit | 57683d5b70be2460a767d1385253d787229214e2 (patch) | |
tree | c140676723e3527ca6527c98b834b1e755757879 /core/helpers | |
parent | dc90ad97396c258f3a5fe9b0c126af33f88a7b4a (diff) |
Change how the modules table doesn't exist is caught. In running unit test, sometimes i would get the message "There was an SQL error: Table 'gallery3_unittest.modules' doesn't exist - ...." and sometimes I would get the message "Table modules does not exist in your database." In both cases the error code was 44.
Diffstat (limited to 'core/helpers')
-rw-r--r-- | core/helpers/core_installer.php | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/core/helpers/core_installer.php b/core/helpers/core_installer.php index bbcf9bd1..89d3f515 100644 --- a/core/helpers/core_installer.php +++ b/core/helpers/core_installer.php @@ -23,7 +23,7 @@ class core_installer { try { $base_version = ORM::factory("module")->where("name", "core")->find()->version; } catch (Exception $e) { - if ($e->getMessage() == "Table modules does not exist in your database.") { + if ($e->getCode() == 44) { $base_version = 0; } else { throw $e; |