Node.js examples for Object:Object Type
Is object Error type
function isError(e) { return isObject(e) && (objectToString(e) === '[object Error]' || e instanceof Error); } function isObject(arg) { return typeof arg === 'object' && arg !== null; }