initial
This commit is contained in:
15
node_modules/har-validator/lib/browser/error.js
generated
vendored
Normal file
15
node_modules/har-validator/lib/browser/error.js
generated
vendored
Normal file
@@ -0,0 +1,15 @@
|
||||
export default function HARError(errors) {
|
||||
let message = 'validation failed';
|
||||
|
||||
this.name = 'HARError';
|
||||
this.message = message;
|
||||
this.errors = errors;
|
||||
|
||||
if (typeof Error.captureStackTrace === 'function') {
|
||||
Error.captureStackTrace(this, this.constructor);
|
||||
} else {
|
||||
this.stack = new Error(message).stack;
|
||||
}
|
||||
}
|
||||
|
||||
HARError.prototype = Error.prototype;
|
||||
Reference in New Issue
Block a user