Enable the no-lonely-if ESLint rule

These changes were mostly done automatically, using `gulp lint --fix`, and only a few spots with comments needed manual tweaking; please see https://eslint.org/docs/latest/rules/no-lonely-if
This commit is contained in:
Jonas Jenwald 2023-07-20 10:57:30 +02:00
parent abb24f82fb
commit c018070e80
15 changed files with 108 additions and 147 deletions

View file

@ -623,11 +623,10 @@ class PDFFindController {
if (newQuery !== prevQuery) {
return true;
}
} else {
// Array
if (JSON.stringify(newQuery) !== JSON.stringify(prevQuery)) {
return true;
}
} else if (
/* isArray && */ JSON.stringify(newQuery) !== JSON.stringify(prevQuery)
) {
return true;
}
switch (state.type) {