From 759d93dc198a3cc8c5265245c0144efa5435682b Mon Sep 17 00:00:00 2001 From: Vijay Aravamudhan Date: Fri, 22 Apr 2022 15:04:21 -0500 Subject: Turn off usage of 'debug' npm package using with electron-16 (fixes #17) --- src/stores/RecipesStore.js | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) (limited to 'src/stores/RecipesStore.js') diff --git a/src/stores/RecipesStore.js b/src/stores/RecipesStore.js index 0a3db2488..d39b87401 100644 --- a/src/stores/RecipesStore.js +++ b/src/stores/RecipesStore.js @@ -8,7 +8,8 @@ import Request from './lib/Request'; import { matchRoute } from '../helpers/routing-helpers'; import { asarRecipesPath } from '../helpers/asar-helpers'; -const debug = require('debug')('Ferdium:RecipeStore'); +// TODO: Go back to 'debug' from 'console.log' when https://github.com/electron/electron/issues/31689 is fixed +// const debug = require('debug')('Ferdium:RecipeStore'); export default class RecipesStore extends Store { @observable allRecipesRequest = new CachedRequest(this.api.recipes, 'all'); @@ -47,7 +48,7 @@ export default class RecipesStore extends Store { return activeRecipe; } - debug(`Recipe ${match.id} not installed`); + console.log(`Recipe ${match.id} not installed`); } return null; @@ -78,7 +79,7 @@ export default class RecipesStore extends Store { const recipes = {}; // Hackfix, reference this.all to fetch services - debug(`Check Recipe updates for ${this.all.map(recipe => recipe.id)}`); + console.log(`Check Recipe updates for ${this.all.map(recipe => recipe.id)}`); for (const r of recipeIds) { const recipe = this.one(r); @@ -107,7 +108,7 @@ export default class RecipesStore extends Store { } const updates = [...remoteUpdates, ...localUpdates]; - debug( + console.log( 'Got update information (local, remote):', localUpdates, remoteUpdates, @@ -145,7 +146,7 @@ export default class RecipesStore extends Store { if (!this.stores.recipes.isInstalled(recipeId)) { router.push('/settings/recipes'); - debug(`Recipe ${recipeId} is not installed, trying to install it`); + console.log(`Recipe ${recipeId} is not installed, trying to install it`); const recipe = await this.installRecipeRequest.execute(recipeId) ._promise; -- cgit v1.2.3-54-g00ecf