diff options
author | 2021-07-02 19:49:55 -0600 | |
---|---|---|
committer | 2021-07-03 07:19:55 +0530 | |
commit | 33123c354b79f7951423dd75097b11e7eb075f99 (patch) | |
tree | 29f6e857f02d0e0fc67d89a657a54a865ed5538a /src/stores | |
parent | Minor refactoring to move all runtime configs from 'config.js' into 'environm... (diff) | |
download | ferdium-app-33123c354b79f7951423dd75097b11e7eb075f99.tar.gz ferdium-app-33123c354b79f7951423dd75097b11e7eb075f99.tar.zst ferdium-app-33123c354b79f7951423dd75097b11e7eb075f99.zip |
Upgrade various dependencies to latest part 2 (#1557)
* Upgrade various dependencies to latest, remove unnecessary electron-hunspell
- upgrade eslint and friends to latest
- remove deprecated 'node-sass' in favor of 'sass'
- disable new rules from 'eslint-config-airbnb' that are conflicting with current code style
- add workspace config for 'vscode' that silences 'experimentalDecorator' warning and forces 'prettier' to single quote
* Run yarn lint to autofix with new ruleset and worked down lint issues to zero
Diffstat (limited to 'src/stores')
-rw-r--r-- | src/stores/AppStore.js | 2 | ||||
-rw-r--r-- | src/stores/FeaturesStore.js | 4 | ||||
-rw-r--r-- | src/stores/ServicesStore.js | 1 |
3 files changed, 3 insertions, 4 deletions
diff --git a/src/stores/AppStore.js b/src/stores/AppStore.js index dd4ab3629..3116677c2 100644 --- a/src/stores/AppStore.js +++ b/src/stores/AppStore.js | |||
@@ -127,7 +127,6 @@ export default class AppStore extends Store { | |||
127 | this.isFullScreen = false; | 127 | this.isFullScreen = false; |
128 | }); | 128 | }); |
129 | 129 | ||
130 | |||
131 | this.isOnline = navigator.onLine; | 130 | this.isOnline = navigator.onLine; |
132 | 131 | ||
133 | // Check if Ferdi should launch on start | 132 | // Check if Ferdi should launch on start |
@@ -474,7 +473,6 @@ export default class AppStore extends Store { | |||
474 | locale = this.stores.user.data.locale; | 473 | locale = this.stores.user.data.locale; |
475 | } | 474 | } |
476 | 475 | ||
477 | |||
478 | if (locale && Object.prototype.hasOwnProperty.call(locales, locale) && locale !== this.locale) { | 476 | if (locale && Object.prototype.hasOwnProperty.call(locales, locale) && locale !== this.locale) { |
479 | this.locale = locale; | 477 | this.locale = locale; |
480 | } else if (!locale) { | 478 | } else if (!locale) { |
diff --git a/src/stores/FeaturesStore.js b/src/stores/FeaturesStore.js index 631d0318e..2fee9bdda 100644 --- a/src/stores/FeaturesStore.js +++ b/src/stores/FeaturesStore.js | |||
@@ -33,7 +33,7 @@ export default class FeaturesStore extends Store { | |||
33 | 33 | ||
34 | @observable featuresRequest = new CachedRequest(this.api.features, 'features'); | 34 | @observable featuresRequest = new CachedRequest(this.api.features, 'features'); |
35 | 35 | ||
36 | @observable features = Object.assign({}, DEFAULT_FEATURES_CONFIG); | 36 | @observable features = ({ ...DEFAULT_FEATURES_CONFIG }); |
37 | 37 | ||
38 | async setup() { | 38 | async setup() { |
39 | this.registerReactions([ | 39 | this.registerReactions([ |
@@ -57,7 +57,7 @@ export default class FeaturesStore extends Store { | |||
57 | } | 57 | } |
58 | 58 | ||
59 | _updateFeatures = () => { | 59 | _updateFeatures = () => { |
60 | const features = Object.assign({}, DEFAULT_FEATURES_CONFIG); | 60 | const features = { ...DEFAULT_FEATURES_CONFIG }; |
61 | if (this.stores.user.isLoggedIn) { | 61 | if (this.stores.user.isLoggedIn) { |
62 | let requestResult = {}; | 62 | let requestResult = {}; |
63 | try { | 63 | try { |
diff --git a/src/stores/ServicesStore.js b/src/stores/ServicesStore.js index 3dba217b2..9b69cb7c6 100644 --- a/src/stores/ServicesStore.js +++ b/src/stores/ServicesStore.js | |||
@@ -306,6 +306,7 @@ export default class ServicesStore extends Store { | |||
306 | } | 306 | } |
307 | 307 | ||
308 | // set default values for serviceData | 308 | // set default values for serviceData |
309 | // eslint-disable-next-line prefer-object-spread | ||
309 | Object.assign({ | 310 | Object.assign({ |
310 | isEnabled: true, | 311 | isEnabled: true, |
311 | isHibernationEnabled: false, | 312 | isHibernationEnabled: false, |