diff options
author | Andrew Dolgov <[email protected]> | 2024-01-09 11:45:40 +0300 |
---|---|---|
committer | Andrew Dolgov <[email protected]> | 2024-01-09 11:45:40 +0300 |
commit | bcdfedeb8a7836c25791d592e5ae4e0f5454c265 (patch) | |
tree | 050bac479a46cac782ac152f7bb280723717ae21 /classes/Pref_Prefs.php | |
parent | ea6cdcccb09f6e254f5de532010b8deea837c339 (diff) |
* mark get_pref/set_pref wrappers as deprecated
* add per-user preference for minimal score required for digest
Diffstat (limited to 'classes/Pref_Prefs.php')
-rw-r--r-- | classes/Pref_Prefs.php | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/classes/Pref_Prefs.php b/classes/Pref_Prefs.php index c9eb89631..31c71e004 100644 --- a/classes/Pref_Prefs.php +++ b/classes/Pref_Prefs.php @@ -74,6 +74,7 @@ class Pref_Prefs extends Handler_Protected { Prefs::DIGEST_ENABLE, Prefs::DIGEST_CATCHUP, Prefs::DIGEST_PREFERRED_TIME, + Prefs::DIGEST_MIN_SCORE, ], __('Advanced') => [ Prefs::BLACKLISTED_TAGS, @@ -127,6 +128,7 @@ class Pref_Prefs extends Handler_Protected { Prefs::DEBUG_HEADLINE_IDS => array(__("Show article and feed IDs"), __("In the headlines buffer")), Prefs::DISABLE_CONDITIONAL_COUNTERS => array(__("Disable conditional counter updates"), __("May increase server load")), Prefs::CDM_ENABLE_GRID => array(__("Grid view"), __("On wider screens, if always expanded")), + Prefs::DIGEST_MIN_SCORE => array(__("Required score"), __("Include articles with this or above score into digest")), ]; // hidden in the main prefs UI (use to hide things that have description set above) @@ -688,7 +690,7 @@ class Pref_Prefs extends Handler_Protected { } } else if (in_array($pref_name, [Prefs::FRESH_ARTICLE_MAX_AGE, - Prefs::PURGE_OLD_DAYS, Prefs::LONG_DATE_FORMAT, Prefs::SHORT_DATE_FORMAT])) { + Prefs::PURGE_OLD_DAYS, Prefs::LONG_DATE_FORMAT, Prefs::SHORT_DATE_FORMAT, Prefs::DIGEST_MIN_SCORE])) { if ($pref_name == Prefs::PURGE_OLD_DAYS && Config::get(Config::FORCE_ARTICLE_PURGE) != 0) { $attributes = ["disabled" => true, "required" => true]; |