diff options
Diffstat (limited to 'mod/logrotate/start.php')
-rw-r--r-- | mod/logrotate/start.php | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/mod/logrotate/start.php b/mod/logrotate/start.php index 28f14ad14..313cf1fd5 100644 --- a/mod/logrotate/start.php +++ b/mod/logrotate/start.php @@ -21,8 +21,11 @@ function logrotate_init() { // Register cron hook for archival of logs elgg_register_plugin_hook_handler('cron', $period, 'logrotate_archive_cron'); - // Register cron hook for deletion of selected archived logs - elgg_register_plugin_hook_handler('cron', $delete, 'logrotate_delete_cron'); + + if ($delete != 'never') { + // Register cron hook for deletion of selected archived logs + elgg_register_plugin_hook_handler('cron', $delete, 'logrotate_delete_cron'); + } } /** |