diff options
author | Abin Mn <abinmn619@gmail.com> | 2021-10-26 21:18:20 +0530 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-10-26 21:18:20 +0530 |
commit | 91c69428ed0dc2dd26b00c6dd5a6684f25515a34 (patch) | |
tree | 062a9a4946aa1367263533682ee59e795ea97234 /src/stores | |
parent | Add feature to display service name under service icon when the toggle for it... (diff) | |
download | ferdium-app-91c69428ed0dc2dd26b00c6dd5a6684f25515a34.tar.gz ferdium-app-91c69428ed0dc2dd26b00c6dd5a6684f25515a34.tar.zst ferdium-app-91c69428ed0dc2dd26b00c6dd5a6684f25515a34.zip |
Cleanup/remove feature toggle for todo, workspace, service proxy (#2134)
* Remove DEFAULT_FEATURES_CONFIG from config
* Remove static controller
Co-authored-by: Madhuri B <MadhuriBandanadam@users.noreply.github.com>
Diffstat (limited to 'src/stores')
-rw-r--r-- | src/stores/FeaturesStore.js | 10 |
1 files changed, 3 insertions, 7 deletions
diff --git a/src/stores/FeaturesStore.js b/src/stores/FeaturesStore.js index 8e0134d7f..fdb502b6b 100644 --- a/src/stores/FeaturesStore.js +++ b/src/stores/FeaturesStore.js | |||
@@ -9,13 +9,10 @@ import workspaces from '../features/workspaces'; | |||
9 | import quickSwitch from '../features/quickSwitch'; | 9 | import quickSwitch from '../features/quickSwitch'; |
10 | import nightlyBuilds from '../features/nightlyBuilds'; | 10 | import nightlyBuilds from '../features/nightlyBuilds'; |
11 | import publishDebugInfo from '../features/publishDebugInfo'; | 11 | import publishDebugInfo from '../features/publishDebugInfo'; |
12 | import settingsWS from '../features/settingsWS'; | ||
13 | import communityRecipes from '../features/communityRecipes'; | 12 | import communityRecipes from '../features/communityRecipes'; |
14 | import todos from '../features/todos'; | 13 | import todos from '../features/todos'; |
15 | import appearance from '../features/appearance'; | 14 | import appearance from '../features/appearance'; |
16 | 15 | ||
17 | import { DEFAULT_FEATURES_CONFIG } from '../config'; | ||
18 | |||
19 | export default class FeaturesStore extends Store { | 16 | export default class FeaturesStore extends Store { |
20 | @observable defaultFeaturesRequest = new CachedRequest( | 17 | @observable defaultFeaturesRequest = new CachedRequest( |
21 | this.api.features, | 18 | this.api.features, |
@@ -27,7 +24,7 @@ export default class FeaturesStore extends Store { | |||
27 | 'features', | 24 | 'features', |
28 | ); | 25 | ); |
29 | 26 | ||
30 | @observable features = { ...DEFAULT_FEATURES_CONFIG }; | 27 | @observable features = { }; |
31 | 28 | ||
32 | async setup() { | 29 | async setup() { |
33 | this.registerReactions([ | 30 | this.registerReactions([ |
@@ -41,12 +38,12 @@ export default class FeaturesStore extends Store { | |||
41 | 38 | ||
42 | @computed get anonymousFeatures() { | 39 | @computed get anonymousFeatures() { |
43 | return ( | 40 | return ( |
44 | this.defaultFeaturesRequest.execute().result || DEFAULT_FEATURES_CONFIG | 41 | this.defaultFeaturesRequest.execute().result || {} |
45 | ); | 42 | ); |
46 | } | 43 | } |
47 | 44 | ||
48 | _updateFeatures = () => { | 45 | _updateFeatures = () => { |
49 | const features = { ...DEFAULT_FEATURES_CONFIG }; | 46 | const features = { }; |
50 | if (this.stores.user.isLoggedIn) { | 47 | if (this.stores.user.isLoggedIn) { |
51 | let requestResult = {}; | 48 | let requestResult = {}; |
52 | try { | 49 | try { |
@@ -77,7 +74,6 @@ export default class FeaturesStore extends Store { | |||
77 | quickSwitch(); | 74 | quickSwitch(); |
78 | nightlyBuilds(); | 75 | nightlyBuilds(); |
79 | publishDebugInfo(); | 76 | publishDebugInfo(); |
80 | settingsWS(this.stores, this.actions); | ||
81 | communityRecipes(this.stores, this.actions); | 77 | communityRecipes(this.stores, this.actions); |
82 | todos(this.stores, this.actions); | 78 | todos(this.stores, this.actions); |
83 | appearance(this.stores); | 79 | appearance(this.stores); |