Improve API error logging to differentiate between builder and client sources

This commit is contained in:
Andrew Kingston 2022-01-24 16:40:55 +00:00
parent c08fadc7b0
commit b33a2aa662
2 changed files with 2 additions and 2 deletions

View File

@ -25,7 +25,7 @@ export const API = createAPIClient({
} }
// Log all errors to console // Log all errors to console
console.error(`HTTP ${status} on ${method}:${url}\n\t${message}`) console.warn(`[Builder] HTTP ${status} on ${method}:${url}\n\t${message}`)
// Logout on 403's // Logout on 403's
if (status === 403) { if (status === 403) {

View File

@ -32,7 +32,7 @@ export const API = createAPIClient({
} }
// Log all errors to console // Log all errors to console
console.error(`HTTP ${status} on ${method}:${url}:\n\t${message}`) console.warn(`[Client] HTTP ${status} on ${method}:${url}\n\t${message}`)
}, },
// Patch certain endpoints with functionality specific to client apps // Patch certain endpoints with functionality specific to client apps