summaryrefslogtreecommitdiffstats
path: root/modules-available/statistics_reporting
diff options
context:
space:
mode:
authorSimon Rettberg2017-03-21 12:18:47 +0100
committerSimon Rettberg2017-03-21 12:18:47 +0100
commitc415a9374872c6235fe822a5e038546522817e3a (patch)
treed04977a0cb1978195af5ce2ce083832de92e7178 /modules-available/statistics_reporting
parent[webinterface] Remember last HTTPS config; add redirect to HTTPS setting (diff)
downloadslx-admin-c415a9374872c6235fe822a5e038546522817e3a.tar.gz
slx-admin-c415a9374872c6235fe822a5e038546522817e3a.tar.xz
slx-admin-c415a9374872c6235fe822a5e038546522817e3a.zip
Fix a couple of warnings and notices from error.log
Diffstat (limited to 'modules-available/statistics_reporting')
-rw-r--r--modules-available/statistics_reporting/inc/remotereport.inc.php8
1 files changed, 4 insertions, 4 deletions
diff --git a/modules-available/statistics_reporting/inc/remotereport.inc.php b/modules-available/statistics_reporting/inc/remotereport.inc.php
index 7aad8b3a..a2234849 100644
--- a/modules-available/statistics_reporting/inc/remotereport.inc.php
+++ b/modules-available/statistics_reporting/inc/remotereport.inc.php
@@ -40,7 +40,7 @@ class RemoteReport
if ($ts === 0) {
// No timestamp stored yet - might be a fresh install
// schedule for next time
- self::updateNextReportingTimestamp();
+ self::writeNextReportingTimestamp();
$ts = Property::get(self::NEXT_SUBMIT_ID, 0);
} elseif ($ts < strtotime('last monday')) {
// Too long ago, move forward to last monday
@@ -63,14 +63,14 @@ class RemoteReport
* Generate the multi-dimensional array containing the anonymized
* (weekly) statistics to report.
*
- * @param $from start timestamp
- * @param $to end timestamp
+ * @param int $from start timestamp
+ * @param int $to end timestamp
* @return array wrapped up statistics, ready for reporting
*/
public static function generateReport($from, $to) {
GetData::$from = $from;
GetData::$to = $to;
- GetData::$salt = bin2hex(Util::randomBytes(20));
+ GetData::$salt = bin2hex(Util::randomBytes(20, false));
$data = GetData::total(GETDATA_ANONYMOUS);
$data['perLocation'] = GetData::perLocation(GETDATA_ANONYMOUS);
$data['perClient'] = GetData::perClient(GETDATA_ANONYMOUS);