diff options
author | sgiehl <stefan@piwik.org> | 2016-10-03 23:17:30 +0300 |
---|---|---|
committer | sgiehl <stefan@piwik.org> | 2016-10-04 00:16:00 +0300 |
commit | 4c38c16a4992ecd8b081ec8264157eeee1a6ecf5 (patch) | |
tree | b751ca132c615854004ded0becfff807e0adbacc /plugins | |
parent | a16ea5af913cc20527cf3f2fbc1766c91c64d366 (diff) |
move timezone offest calculation to date class
Diffstat (limited to 'plugins')
-rw-r--r-- | plugins/ScheduledReports/Controller.php | 5 |
1 files changed, 1 insertions, 4 deletions
diff --git a/plugins/ScheduledReports/Controller.php b/plugins/ScheduledReports/Controller.php index 8bdca90ab7..789b30fbc4 100644 --- a/plugins/ScheduledReports/Controller.php +++ b/plugins/ScheduledReports/Controller.php @@ -29,10 +29,7 @@ class Controller extends \Piwik\Plugin\Controller $siteTimezone = $this->site->getTimezone(); - $timestampUTC = Date::today()->getTimestampUTC(); - $timestampZone = Date::adjustForTimezone($timestampUTC, $siteTimezone); - - $view->timeZoneDifference = ($timestampZone - $timestampUTC) / 3600; + $view->timeZoneDifference = Date::getUtcOffset($siteTimezone) / 3600; $view->countWebsites = count(APISitesManager::getInstance()->getSitesIdWithAtLeastViewAccess()); // get report types |