From c04f60944106dbd8d1bf2fb5ce0e7be644c3abc6 Mon Sep 17 00:00:00 2001 From: Ali Mihandoost Date: Wed, 19 Apr 2023 22:19:25 +0330 Subject: [PATCH] fix(fetch): suppress fetch_cache_not_found extra error --- core/fetch/src/fetch.ts | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/core/fetch/src/fetch.ts b/core/fetch/src/fetch.ts index b7622e93f..671eb4fac 100644 --- a/core/fetch/src/fetch.ts +++ b/core/fetch/src/fetch.ts @@ -84,7 +84,10 @@ export async function serviceRequest< response = await fetch(options); } catch (err) { - logger.error('serviceRequest', (err as Error).message || 'fetch_failed', err, options); + const errMessage = (err as Error).message; + if (errMessage !== 'fetch_cache_not_found') { + logger.error('serviceRequest', (err as Error).message || 'fetch_failed', err, options); + } throw err; }