aboutsummaryrefslogtreecommitdiffstats
path: root/src/features/communityRecipes/store.js
diff options
context:
space:
mode:
authorLibravatar Markus Hatvan <markus_hatvan@aon.at>2021-10-02 09:24:32 +0200
committerLibravatar GitHub <noreply@github.com>2021-10-02 09:24:32 +0200
commitbfe8847d72cd0893230f2e654242658214943e61 (patch)
tree3384b02ebad7a74cbb106ddd95546e0e24ff0bb8 /src/features/communityRecipes/store.js
parentfix: Fix navigation shortcut accelerator for non-macos (fixes #1172) (#2012) (diff)
downloadferdium-app-bfe8847d72cd0893230f2e654242658214943e61.tar.gz
ferdium-app-bfe8847d72cd0893230f2e654242658214943e61.tar.zst
ferdium-app-bfe8847d72cd0893230f2e654242658214943e61.zip
chore: convert various files from JS to TS (#2010)
Diffstat (limited to 'src/features/communityRecipes/store.js')
-rw-r--r--src/features/communityRecipes/store.js32
1 files changed, 0 insertions, 32 deletions
diff --git a/src/features/communityRecipes/store.js b/src/features/communityRecipes/store.js
deleted file mode 100644
index 05e18e2f7..000000000
--- a/src/features/communityRecipes/store.js
+++ /dev/null
@@ -1,32 +0,0 @@
1import { computed } from 'mobx';
2import { FeatureStore } from '../utils/FeatureStore';
3
4const debug = require('debug')('Ferdi:feature:communityRecipes:store');
5
6export class CommunityRecipesStore extends FeatureStore {
7 start(stores, actions) {
8 debug('start');
9 this.stores = stores;
10 this.actions = actions;
11 }
12
13 stop() {
14 debug('stop');
15 super.stop();
16 }
17
18 @computed get communityRecipes() {
19 if (!this.stores) return [];
20
21 return this.stores.recipePreviews.dev.map(recipePreview => {
22 // TODO: Need to figure out if this is even necessary/used
23 recipePreview.isDevRecipe = !!recipePreview.author.some(
24 author => author.email === this.stores.user.data.email,
25 );
26
27 return recipePreview;
28 });
29 }
30}
31
32export default CommunityRecipesStore;