mirror of
https://github.com/titanscouting/tra-analysis.git
synced 2024-11-10 15:04:45 +00:00
19 lines
330 B
JavaScript
19 lines
330 B
JavaScript
'use strict';
|
|
|
|
module.exports = Error.captureStackTrace || function (error) {
|
|
var container = new Error();
|
|
|
|
Object.defineProperty(error, 'stack', {
|
|
configurable: true,
|
|
get: function getStack() {
|
|
var stack = container.stack;
|
|
|
|
Object.defineProperty(this, 'stack', {
|
|
value: stack
|
|
});
|
|
|
|
return stack;
|
|
}
|
|
});
|
|
};
|