function notifications_update_1 in Notifications 6
Same name and namespace in other branches
- 5 notifications.install \notifications_update_1()
- 6.4 notifications.install \notifications_update_1()
- 6.2 notifications.install \notifications_update_1()
- 6.3 notifications.install \notifications_update_1()
Update: Add cron flag for processing
File
- ./
notifications.install, line 98
Code
function notifications_update_1() {
$ret = array();
// Add field
$ret[] = update_sql("ALTER TABLE {notifications} ADD COLUMN `cron` TINYINT UNSIGNED NOT NULL DEFAULT 0");
$ret[] = update_sql("ALTER TABLE {notifications_queue} ADD COLUMN `cron` TINYINT UNSIGNED NOT NULL DEFAULT 0");
// Populate field, this is new so all stored rows till now should be intended for cron processing
$ret[] = update_sql("UPDATE {notifications} SET cron = 1");
$ret[] = update_sql("UPDATE {notifications_queue} SET cron = 1");
return $ret;
}