From dd983e5de1e28218329854b1033dcd2b848229bf Mon Sep 17 00:00:00 2001 From: Andrew Dolgov Date: Sun, 5 Jun 2022 11:45:13 +0300 Subject: prefs: move external filter tree onload method (which checks for inactive feeds, etc.) to FilterTree class --- js/PrefFeedTree.js | 10 ++++++++++ 1 file changed, 10 insertions(+) (limited to 'js') diff --git a/js/PrefFeedTree.js b/js/PrefFeedTree.js index 013c01262..0585173c9 100644 --- a/js/PrefFeedTree.js +++ b/js/PrefFeedTree.js @@ -5,6 +5,16 @@ define(["dojo/_base/declare", "dojo/dom-construct", "lib/CheckBoxTree", "dojo/_b function (declare, domConstruct, checkBoxTree, array, cookie) { return declare("fox.PrefFeedTree", lib.CheckBoxTree, { + postCreate: function() { + this.inherited(arguments); + + const tmph = dojo.connect(this, 'onLoad', () => { + dojo.disconnect(tmph); + + this.checkInactiveFeeds(); + this.checkErrorFeeds(); + }); + }, // save state in localStorage instead of cookies // reference: https://stackoverflow.com/a/27968996 _saveExpandedNodes: function(){ -- cgit v1.2.3