diff options
Diffstat (limited to 'src/api')
-rw-r--r-- | src/api/server/ServerApi.ts | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/api/server/ServerApi.ts b/src/api/server/ServerApi.ts index 2fd1a8d0d..0144a1069 100644 --- a/src/api/server/ServerApi.ts +++ b/src/api/server/ServerApi.ts | |||
@@ -368,11 +368,12 @@ export default class ServerApi { | |||
368 | } | 368 | } |
369 | 369 | ||
370 | async getFeaturedRecipePreviews() { | 370 | async getFeaturedRecipePreviews() { |
371 | // TODO: If we are hitting the internal-server, we need to return an empty list, else we can hit the remote server and get the data | ||
372 | const request = await sendAuthRequest(`${apiBase()}/recipes/popular`); | 371 | const request = await sendAuthRequest(`${apiBase()}/recipes/popular`); |
373 | if (!request.ok) throw new Error(request.statusText); | 372 | if (!request.ok) throw new Error(request.statusText); |
374 | 373 | ||
375 | const data = await request.json(); | 374 | const data = await request.json(); |
375 | // data = this._addLocalRecipesToPreviews(data); | ||
376 | |||
376 | const recipePreviews = this._mapRecipePreviewModel(data); | 377 | const recipePreviews = this._mapRecipePreviewModel(data); |
377 | debug('ServerApi::getFeaturedRecipes resolves', recipePreviews); | 378 | debug('ServerApi::getFeaturedRecipes resolves', recipePreviews); |
378 | return recipePreviews; | 379 | return recipePreviews; |