@vue-storefront/middleware
Advanced tools
Comparing version 3.3.0 to 3.3.1
@@ -63,5 +63,6 @@ 'use strict'; | ||
function isErrorObject(obj) { | ||
/* c8 ignore next */ | ||
const name = (obj ?? false)?.constructor?.name; | ||
return name === 'Error' || name === 'Object'; | ||
// typeof null is 'object' https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Operators/typeof#typeof_null | ||
if (obj === null) | ||
return false; | ||
return typeof obj === 'object'; | ||
} | ||
@@ -68,0 +69,0 @@ function isAxiosError(error) { |
@@ -51,5 +51,6 @@ import consola from 'consola'; | ||
function isErrorObject(obj) { | ||
/* c8 ignore next */ | ||
const name = (obj ?? false)?.constructor?.name; | ||
return name === 'Error' || name === 'Object'; | ||
// typeof null is 'object' https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Operators/typeof#typeof_null | ||
if (obj === null) | ||
return false; | ||
return typeof obj === 'object'; | ||
} | ||
@@ -56,0 +57,0 @@ function isAxiosError(error) { |
{ | ||
"name": "@vue-storefront/middleware", | ||
"version": "3.3.0", | ||
"version": "3.3.1", | ||
"main": "lib/index.cjs.js", | ||
@@ -5,0 +5,0 @@ "module": "lib/index.es.js", |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
61218
977