diff options
Diffstat (limited to 'modules/system/system.install')
-rw-r--r-- | modules/system/system.install | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/modules/system/system.install b/modules/system/system.install index af2ceab33..45a690198 100644 --- a/modules/system/system.install +++ b/modules/system/system.install @@ -143,10 +143,10 @@ function system_requirements($phase) { // Determine severity based on time since cron last ran. $severity = REQUIREMENT_OK; - if ($_SERVER['REQUEST_TIME'] - $cron_last > $threshold_error) { + if (REQUEST_TIME - $cron_last > $threshold_error) { $severity = REQUIREMENT_ERROR; } - else if ($never_run || ($_SERVER['REQUEST_TIME'] - $cron_last > $threshold_warning)) { + else if ($never_run || (REQUEST_TIME - $cron_last > $threshold_warning)) { $severity = REQUIREMENT_WARNING; } @@ -163,7 +163,7 @@ function system_requirements($phase) { $description = $t('Cron has not run.') . ' ' . $help; } else { - $summary = $t('Last run !time ago', array('!time' => format_interval($_SERVER['REQUEST_TIME'] - $cron_last))); + $summary = $t('Last run !time ago', array('!time' => format_interval(REQUEST_TIME - $cron_last))); $description = ''; if ($severity != REQUIREMENT_OK) { $description = $t('Cron has not run recently.') . ' ' . $help; @@ -371,7 +371,7 @@ function system_install() { // presumed to be a serialized array. Install will change uid 1 immediately // anyways. So we insert the superuser here, the uid is 2 here for now, but // very soon it will be changed to 1. - db_query("INSERT INTO {users} (name, mail, created, data) VALUES('%s', '%s', %d, '%s')", 'placeholder-for-uid-1', 'placeholder-for-uid-1', $_SERVER['REQUEST_TIME'], serialize(array())); + db_query("INSERT INTO {users} (name, mail, created, data) VALUES('%s', '%s', %d, '%s')", 'placeholder-for-uid-1', 'placeholder-for-uid-1', REQUEST_TIME, serialize(array())); // This sets the above two users uid 0 (anonymous). We avoid an explicit 0 // otherwise MySQL might insert the next auto_increment value. db_query("UPDATE {users} SET uid = uid - uid WHERE name = '%s'", ''); |