diff options
author | 2021-09-14 19:58:52 +0200 | |
---|---|---|
committer | 2021-09-14 19:58:52 +0200 | |
commit | 95df3522a15631abc51a4295cae0ea401a8d4e1e (patch) | |
tree | e5eb0f368c947683f01458e912f21756fb0d99cb /src/components/settings | |
parent | docs: add sad270 as a contributor for bug, userTesting [skip ci] (#1941) (diff) | |
download | ferdium-app-95df3522a15631abc51a4295cae0ea401a8d4e1e.tar.gz ferdium-app-95df3522a15631abc51a4295cae0ea401a8d4e1e.tar.zst ferdium-app-95df3522a15631abc51a4295cae0ea401a8d4e1e.zip |
feat: add eslint-plugin-unicorn (#1936)
Diffstat (limited to 'src/components/settings')
-rw-r--r-- | src/components/settings/SettingsLayout.js | 1 | ||||
-rw-r--r-- | src/components/settings/services/EditServiceForm.js | 4 | ||||
-rw-r--r-- | src/components/settings/services/ServicesDashboard.js | 2 |
3 files changed, 4 insertions, 3 deletions
diff --git a/src/components/settings/SettingsLayout.js b/src/components/settings/SettingsLayout.js index 0574b3765..71250bd4d 100644 --- a/src/components/settings/SettingsLayout.js +++ b/src/components/settings/SettingsLayout.js | |||
@@ -29,6 +29,7 @@ class SettingsLayout extends Component { | |||
29 | componentWillUnmount() { | 29 | componentWillUnmount() { |
30 | document.removeEventListener( | 30 | document.removeEventListener( |
31 | 'keydown', | 31 | 'keydown', |
32 | // eslint-disable-next-line unicorn/no-invalid-remove-event-listener | ||
32 | this.handleKeyDown.bind(this), | 33 | this.handleKeyDown.bind(this), |
33 | false, | 34 | false, |
34 | ); | 35 | ); |
diff --git a/src/components/settings/services/EditServiceForm.js b/src/components/settings/services/EditServiceForm.js index 9a9abeab4..7df6d5c78 100644 --- a/src/components/settings/services/EditServiceForm.js +++ b/src/components/settings/services/EditServiceForm.js | |||
@@ -183,8 +183,8 @@ class EditServiceForm extends Component { | |||
183 | removeTrailingSlash: false, | 183 | removeTrailingSlash: false, |
184 | }); | 184 | }); |
185 | isValid = await recipe.validateUrl(values.customUrl); | 185 | isValid = await recipe.validateUrl(values.customUrl); |
186 | } catch (err) { | 186 | } catch (error) { |
187 | console.warn('ValidateURL', err); | 187 | console.warn('ValidateURL', error); |
188 | isValid = false; | 188 | isValid = false; |
189 | } | 189 | } |
190 | } | 190 | } |
diff --git a/src/components/settings/services/ServicesDashboard.js b/src/components/settings/services/ServicesDashboard.js index 847f2ea06..9272b05c9 100644 --- a/src/components/settings/services/ServicesDashboard.js +++ b/src/components/settings/services/ServicesDashboard.js | |||
@@ -91,7 +91,7 @@ class ServicesDashboard extends Component { | |||
91 | <h1>{intl.formatMessage(messages.headline)}</h1> | 91 | <h1>{intl.formatMessage(messages.headline)}</h1> |
92 | </div> | 92 | </div> |
93 | <div className="settings__body"> | 93 | <div className="settings__body"> |
94 | {(services.length !== 0 || searchNeedle) && !isLoading && ( | 94 | {(services.length > 0 || searchNeedle) && !isLoading && ( |
95 | <SearchInput | 95 | <SearchInput |
96 | placeholder={intl.formatMessage(messages.searchService)} | 96 | placeholder={intl.formatMessage(messages.searchService)} |
97 | onChange={needle => filterServices({ needle })} | 97 | onChange={needle => filterServices({ needle })} |