aboutsummaryrefslogtreecommitdiff
path: root/app
diff options
context:
space:
mode:
authorGravatar Alexandre Alapetite <alexandre@alapetite.fr> 2020-05-30 22:48:00 +0200
committerGravatar GitHub <noreply@github.com> 2020-05-30 22:48:00 +0200
commite58ad65902ffb5d2fdbf34a2b63e383ec9919f4d (patch)
tree356466325b2974d328ad5b927212272869c22664 /app
parentb4649b640fe19dffb951ddb3ea52d4256cd2f1c4 (diff)
Fix display_categories upgrade from 1.16.0 again (#3019)
* Fix display_categories upgrade from 1.16.0 again #fix https://github.com/FreshRSS/FreshRSS/issues/3017 Follow-up of https://github.com/FreshRSS/FreshRSS/pull/3018 There were two bugs. I forgot that `ConfigurationSetter.php` is not called when reading `config.php` * Changelog 3019
Diffstat (limited to 'app')
-rw-r--r--app/Models/Context.php5
1 files changed, 5 insertions, 0 deletions
diff --git a/app/Models/Context.php b/app/Models/Context.php
index e27330665..c5dcbdcdb 100644
--- a/app/Models/Context.php
+++ b/app/Models/Context.php
@@ -69,6 +69,11 @@ class FreshRSS_Context {
}
FreshRSS_Context::$user_conf->archiving = $archiving;
}
+
+ //Legacy < 1.16.1
+ if (!in_array(FreshRSS_Context::$user_conf->display_categories, [ 'active', 'all', 'none' ], true)) {
+ FreshRSS_Context::$user_conf->display_categories = FreshRSS_Context::$user_conf->display_categories === true ? 'all' : 'active';
+ }
}
/**