From d9502c7516bc2d4ae467c6ea8a2e4816b0885f37 Mon Sep 17 00:00:00 2001 From: muhamedsalih-tw <104364298+muhamedsalih-tw@users.noreply.github.com> Date: Thu, 17 Nov 2022 05:45:39 +0530 Subject: Transfrom workspace components to ts (#775) --- src/stores/RecipesStore.ts | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'src/stores/RecipesStore.ts') diff --git a/src/stores/RecipesStore.ts b/src/stores/RecipesStore.ts index 25304e97c..07f1343f8 100644 --- a/src/stores/RecipesStore.ts +++ b/src/stores/RecipesStore.ts @@ -74,8 +74,8 @@ export default class RecipesStore extends TypedStore { // Actions async _install({ recipeId }): Promise { - const recipe = await this.installRecipeRequest.execute(recipeId)._promise; - await this.allRecipesRequest.invalidate({ immediately: true })._promise; + const recipe = await this.installRecipeRequest.execute(recipeId).promise; + await this.allRecipesRequest.invalidate({ immediately: true }).promise; return recipe; } @@ -128,7 +128,7 @@ export default class RecipesStore extends TypedStore { const update = updates[i]; this.actions.recipe.install({ recipeId: update }); - await this.installRecipeRequest._promise; + await this.installRecipeRequest.promise; this.installRecipeRequest.reset(); @@ -158,10 +158,10 @@ export default class RecipesStore extends TypedStore { debug(`Recipe ${recipeId} is not installed, trying to install it`); const recipe = await this.installRecipeRequest.execute(recipeId) - ._promise; + .promise; if (recipe) { await this.allRecipesRequest.invalidate({ immediately: true }) - ._promise; + .promise; router.push(`/settings/services/add/${recipeId}`); } else { router.push('/settings/recipes'); -- cgit v1.2.3-54-g00ecf