aboutsummaryrefslogtreecommitdiffstats
path: root/src/stores
diff options
context:
space:
mode:
authorLibravatar Stefan Malzner <stefan@adlk.io>2017-10-24 13:32:07 +0200
committerLibravatar Stefan Malzner <stefan@adlk.io>2017-10-24 13:32:19 +0200
commitf4b2e88a2572359f0911f3a189a2275b57f81fdb (patch)
treea42158aec180f3b6652ad0da7f2c319a4d4474f5 /src/stores
parentImprove recipe bulk download (diff)
downloadferdium-app-f4b2e88a2572359f0911f3a189a2275b57f81fdb.tar.gz
ferdium-app-f4b2e88a2572359f0911f3a189a2275b57f81fdb.tar.zst
ferdium-app-f4b2e88a2572359f0911f3a189a2275b57f81fdb.zip
Fix recipe update loop
Diffstat (limited to 'src/stores')
-rw-r--r--src/stores/AppStore.js2
-rw-r--r--src/stores/RecipesStore.js4
2 files changed, 5 insertions, 1 deletions
diff --git a/src/stores/AppStore.js b/src/stores/AppStore.js
index 8435c9ab8..7dbef985d 100644
--- a/src/stores/AppStore.js
+++ b/src/stores/AppStore.js
@@ -80,7 +80,7 @@ export default class AppStore extends Store {
80 // Check for updates once every 4 hours 80 // Check for updates once every 4 hours
81 setInterval(() => this._checkForUpdates(), CHECK_INTERVAL); 81 setInterval(() => this._checkForUpdates(), CHECK_INTERVAL);
82 // Check for an update in 30s (need a delay to prevent Squirrel Installer lock file issues) 82 // Check for an update in 30s (need a delay to prevent Squirrel Installer lock file issues)
83 setTimeout(() => this._checkForUpdates(), 3000); 83 setTimeout(() => this._checkForUpdates(), 30000);
84 ipcRenderer.on('autoUpdate', (event, data) => { 84 ipcRenderer.on('autoUpdate', (event, data) => {
85 if (data.available) { 85 if (data.available) {
86 this.updateStatus = this.updateStatusTypes.AVAILABLE; 86 this.updateStatus = this.updateStatusTypes.AVAILABLE;
diff --git a/src/stores/RecipesStore.js b/src/stores/RecipesStore.js
index cdc274685..67fee1d50 100644
--- a/src/stores/RecipesStore.js
+++ b/src/stores/RecipesStore.js
@@ -65,6 +65,10 @@ export default class RecipesStore extends Store {
65 @action async _update() { 65 @action async _update() {
66 const recipeIds = this.recipeIdForServices; 66 const recipeIds = this.recipeIdForServices;
67 const recipes = {}; 67 const recipes = {};
68
69 // Hackfix, reference this.all to fetch services
70 console.debug(`Check Recipe updates for ${this.all.map(recipe => recipe.id)}`);
71
68 recipeIds.forEach((r) => { 72 recipeIds.forEach((r) => {
69 const recipe = this.one(r); 73 const recipe = this.one(r);
70 recipes[r] = recipe.version; 74 recipes[r] = recipe.version;