1
0
Fork 0
mirror of https://github.com/mealie-recipes/mealie.git synced 2025-08-05 13:35:23 +02:00

Add Database Layer for Recipe Scaling (#506)

* move badge

* fix add individual ingredient

* fix redirect issue

Co-authored-by: hay-kot <hay-kot@pm.me>
This commit is contained in:
Hayden 2021-06-12 22:23:23 -08:00 committed by GitHub
parent 0a927afaa0
commit e95ca870b1
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
18 changed files with 298 additions and 62 deletions

View file

@ -35,9 +35,11 @@ export const recipeAPI = {
},
async requestDetails(recipeSlug) {
let response = await apiReq.get(API_ROUTES.recipesRecipeSlug(recipeSlug));
if (response && response.data) return response.data;
else return null;
const response = await apiReq.get(API_ROUTES.recipesRecipeSlug(recipeSlug));
if (response.response) {
return response.response;
}
return response;
},
updateImage(recipeSlug, fileObject, overrideSuccessMsg = false) {