diff options
author | diosmosis <benaka@piwik.pro> | 2015-02-03 00:46:19 +0300 |
---|---|---|
committer | diosmosis <benaka@piwik.pro> | 2015-02-05 00:00:59 +0300 |
commit | 75f3a9ffe4f5590f62124ed2717b08a8ea35ce80 (patch) | |
tree | 97b581c0f31099bf269422be285872e9f0f31b28 /core/ArchiveProcessor | |
parent | c89d0942b60c025dc12b70137acf5dbe6f0186ee (diff) |
Do not use php-di config for option since it is easier to use INI config w/o adding documented default in global.ini.php and just handle case where config option is not defined.
Diffstat (limited to 'core/ArchiveProcessor')
-rw-r--r-- | core/ArchiveProcessor/Rules.php | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/core/ArchiveProcessor/Rules.php b/core/ArchiveProcessor/Rules.php index 7b8bffb520..37d65b94e2 100644 --- a/core/ArchiveProcessor/Rules.php +++ b/core/ArchiveProcessor/Rules.php @@ -229,8 +229,12 @@ class Rules public static function isArchivingDisabledFor(array $idSites, Segment $segment, $periodLabel) { + $generalConfig = Config::getInstance()->General; + if ($periodLabel == 'range') { - if (StaticContainer::get('archiving.range.force_on_browser_request') !== false) { + if (empty($generalConfig['archiving_range_force_on_browser_request']) + || $generalConfig['archiving_range_force_on_browser_request'] !== false + ) { return false; } else { Log::verbose("Not forcing archiving for range period."); @@ -246,7 +250,7 @@ class Rules // When there is a segment, we disable archiving when browser_archiving_disabled_enforce applies if (!$segment->isEmpty() && $isArchivingDisabled - && Config::getInstance()->General['browser_archiving_disabled_enforce'] + && $generalConfig['browser_archiving_disabled_enforce'] && !SettingsServer::isArchivePhpTriggered() // Only applies when we are not running core:archive command ) { Log::debug("Archiving is disabled because of config setting browser_archiving_disabled_enforce=1"); |