diff options
author | Dries Buytaert <dries@buytaert.net> | 2004-11-02 15:09:09 +0000 |
---|---|---|
committer | Dries Buytaert <dries@buytaert.net> | 2004-11-02 15:09:09 +0000 |
commit | b94f9af24f1dff4439051787adb6d2a60ed291ad (patch) | |
tree | df288db913fd1a1dd5107c530fca494388c875ac /modules/statistics/statistics.module | |
parent | 95595ae6f821fd616a60031b166b035482736c10 (diff) | |
download | brdo-b94f9af24f1dff4439051787adb6d2a60ed291ad.tar.gz brdo-b94f9af24f1dff4439051787adb6d2a60ed291ad.tar.bz2 |
- Patch #12455 by Steven: optimized SQL query. This problem caused Drupal.org's
cron runs to time out.
Diffstat (limited to 'modules/statistics/statistics.module')
-rw-r--r-- | modules/statistics/statistics.module | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/modules/statistics/statistics.module b/modules/statistics/statistics.module index 895f0083b..c2645d434 100644 --- a/modules/statistics/statistics.module +++ b/modules/statistics/statistics.module @@ -487,7 +487,7 @@ function statistics_cron() { } /* clean expired access logs */ - db_query('DELETE FROM {accesslog} WHERE '. time() .' - timestamp > '. variable_get('statistics_flush_accesslog_timer', 259200)); + db_query('DELETE FROM {accesslog} WHERE timestamp < %d', time() - variable_get('statistics_flush_accesslog_timer', 259200)); } /** |