Index: sites/all/modules/signup_scheduler/signup_scheduler.install =================================================================== --- sites/all/modules/signup_scheduler/signup_scheduler.install (revision 2524) +++ sites/all/modules/signup_scheduler/signup_scheduler.install (working copy) @@ -23,6 +23,10 @@ close int(11) NOT NULL, PRIMARY KEY (nid) ) /*!40100 DEFAULT CHARACTER SET utf8 */;"); + + $weight = db_result(db_query("SELECT weight FROM {system} WHERE name = 'signup'")); + $new_weight = $weight + 1; + db_query("UPDATE {system} SET weight = %d WHERE name = 'signup_scheduler' LIMIT 1", $new_weight); break; } } @@ -39,4 +43,15 @@ while ($variable = db_fetch_object($variables)) { variable_del($variable->name); } +} + +/** + * Implementation of hook_update() + * Set the weight of the signup_scheduler module to be heavier of + * that of the signup module, so it always runs after. + */ +function signup_scheduler_update_1() { + $weight = db_result(db_query("SELECT weight FROM {system} WHERE name = 'signup'")); + $new_weight = $weight + 1; + return array(update_sql("UPDATE {system} SET weight = ". $new_weight ." WHERE name = 'signup_scheduler' LIMIT 1")); } \ No newline at end of file