i broke hide_filters oops

This commit is contained in:
Rhiannon Morris 2022-01-02 00:04:31 +01:00
parent 3be9e79615
commit ed18b1113e

View file

@ -100,7 +100,8 @@ function useFragment() {
clearForm(); clearForm();
} else { } else {
let set = new Set(frag.split(';')); let set = new Set(frag.split(';'));
if (new Array(...set).every(x => /^(require|exclude)_/.test(x))) { let re = /^(require|exclude)_|hide_filters/;
if (new Array(...set).every(x => re.test(x))) {
allBoxes.forEach(b => b.checked = set.has(b.id)); allBoxes.forEach(b => b.checked = set.has(b.id));
let details = document.getElementById('filters-details'); let details = document.getElementById('filters-details');
details.open = !set.has('hide_filters'); details.open = !set.has('hide_filters');