summaryrefslogtreecommitdiffstats
path: root/modules-available/statistics_reporting
diff options
context:
space:
mode:
authorSimon Rettberg2017-04-10 14:45:33 +0200
committerSimon Rettberg2017-04-10 14:45:33 +0200
commit106bc16250bf7fb99a451d64783f705aa6ac212d (patch)
treeefca9073f812c0bac7a0a1f592359aab1b5b4a08 /modules-available/statistics_reporting
parent[statistics_reporting] Don't include perUser and perClient in remote report (diff)
downloadslx-admin-106bc16250bf7fb99a451d64783f705aa6ac212d.tar.gz
slx-admin-106bc16250bf7fb99a451d64783f705aa6ac212d.tar.xz
slx-admin-106bc16250bf7fb99a451d64783f705aa6ac212d.zip
[statistics_reporting] Send backlogged reports in cronjob
Diffstat (limited to 'modules-available/statistics_reporting')
-rw-r--r--modules-available/statistics_reporting/hooks/cron.inc.php3
1 files changed, 2 insertions, 1 deletions
diff --git a/modules-available/statistics_reporting/hooks/cron.inc.php b/modules-available/statistics_reporting/hooks/cron.inc.php
index 45f39719..afb18a23 100644
--- a/modules-available/statistics_reporting/hooks/cron.inc.php
+++ b/modules-available/statistics_reporting/hooks/cron.inc.php
@@ -4,7 +4,7 @@ if (RemoteReport::isReportingEnabled()) {
$nextReporting = RemoteReport::getReportingTimestamp();
// It's time to generate a new report
- if ($nextReporting <= time()) {
+ while ($nextReporting <= time()) {
RemoteReport::writeNextReportingTimestamp();
$from = strtotime("-7 days", $nextReporting);
@@ -21,5 +21,6 @@ if (RemoteReport::isReportingEnabled()) {
} else {
EventLog::info('Statistics report sent to ' . CONFIG_REPORTING_URL);
}
+ $nextReporting = strtotime("+7 days", $nextReporting);
}
} \ No newline at end of file