From e5b0e5f76c0695a01d13c55147a8287df8750594 Mon Sep 17 00:00:00 2001 From: Dries Buytaert Date: Sat, 6 Sep 2008 08:36:22 +0000 Subject: - Patch #302763 by Dave Reid, Rob Loach: replace time() by ['REQUEST_TIME'] as per Rasmus' suggestion. Removed drupal_referrer() for consistency. --- modules/update/update.module | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'modules/update/update.module') diff --git a/modules/update/update.module b/modules/update/update.module index 8a08f986c..15ca24d25 100644 --- a/modules/update/update.module +++ b/modules/update/update.module @@ -276,7 +276,7 @@ function _update_requirement_check($project, $type) { function update_cron() { $frequency = variable_get('update_check_frequency', 1); $interval = 60 * 60 * 24 * $frequency; - if (time() - variable_get('update_last_check', 0) > $interval) { + if ($_SERVER['REQUEST_TIME'] - variable_get('update_last_check', 0) > $interval) { update_refresh(); _update_cron_notify(); } @@ -342,7 +342,7 @@ function update_get_available($refresh = FALSE) { } } if (!$needs_refresh && ($cache = cache_get('update_info', 'cache_update')) - && $cache->expire > time()) { + && $cache->expire > $_SERVER['REQUEST_TIME']) { $available = $cache->data; } elseif ($needs_refresh || $refresh) { -- cgit v1.2.3