mirror of
https://git.tt-rss.org/git/tt-rss.git
synced 2025-12-13 19:35:55 +00:00
* filters: remove duplicate code, overall cleanup
* check if some tres exist before trying to reload them
This commit is contained in:
@@ -96,7 +96,8 @@ define(["dojo/_base/declare", "dojo/dom-construct", "lib/CheckBoxTree", "dijit/f
|
||||
};
|
||||
|
||||
xhrPost("backend.php", query, () => {
|
||||
dijit.byId("filterTree").reload(); // maybe there's labels in there
|
||||
const tree = dijit.byId("filterTree");
|
||||
if (tree) tree.reload(); // maybe there's labels in there
|
||||
});
|
||||
|
||||
},
|
||||
@@ -111,7 +112,8 @@ define(["dojo/_base/declare", "dojo/dom-construct", "lib/CheckBoxTree", "dijit/f
|
||||
this.hide();
|
||||
|
||||
xhrPost("backend.php", this.attr('value'), () => {
|
||||
dijit.byId("filterTree").reload(); // maybe there's labels in there
|
||||
const tree = dijit.byId("filterTree");
|
||||
if (tree) tree.reload(); // maybe there's labels in there
|
||||
});
|
||||
}
|
||||
},
|
||||
|
||||
Reference in New Issue
Block a user