清空
This commit is contained in:
1 parent
7c2ab0b7ad
commit
cff33ad7d1
6370 files changed
+378844
-82245
No files matched your search
+14
@@ -0,0 +1,14 @@
|
||||
'use strict';
|
||||
var createNonEnumerableProperty = require('../internals/create-non-enumerable-property');
|
||||
var clearErrorStack = require('../internals/error-stack-clear');
|
||||
var ERROR_STACK_INSTALLABLE = require('../internals/error-stack-installable');
|
||||
|
||||
// non-standard V8
|
||||
var captureStackTrace = Error.captureStackTrace;
|
||||
|
||||
module.exports = function (error, C, stack, dropEntries) {
|
||||
if (ERROR_STACK_INSTALLABLE) {
|
||||
if (captureStackTrace) captureStackTrace(error, C);
|
||||
else createNonEnumerableProperty(error, 'stack', clearErrorStack(stack, dropEntries));
|
||||
}
|
||||
};
|
||||
Reference in new issue
Block a user