diff options
-rw-r--r-- | includes/install.inc | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/includes/install.inc b/includes/install.inc index 1fb13883b..2e1f256d8 100644 --- a/includes/install.inc +++ b/includes/install.inc @@ -93,12 +93,10 @@ function drupal_load_updates() { */ function drupal_get_schema_versions($module) { $updates = &drupal_static(__FUNCTION__, NULL); - if (!isset($updates)) { + if (!isset($updates[$module])) { $updates = array(); // Prepare regular expression to match all possible defined hook_update_N(). - $modules = db_query("SELECT name FROM {system} WHERE type = 'module'") - ->fetchCol(); - $regexp = '/^(?P<module>' . implode('|', $modules) . ')_update_(?P<version>\d+)$/'; + $regexp = '/^(?P<module>.+)_update_(?P<version>\d+)$/'; $functions = get_defined_functions(); // Narrow this down to functions ending with an integer, since all // hook_update_N() functions end this way, and there are other |