We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
lib/assert.js
1 parent fd7e4ab commit 1fe0b69Copy full SHA for 1fe0b69
lib/assert.js
@@ -965,10 +965,10 @@ assert.ifError = function ifError(err) {
965
// This will remove any duplicated frames from the error frames taken
966
// from within `ifError` and add the original error frames to the newly
967
// created ones.
968
- const origStackStart = origStack.indexOf('\n at');
+ const origStackStart = StringPrototypeIndexOf(origStack, '\n at');
969
if (origStackStart !== -1) {
970
const originalFrames = StringPrototypeSplit(
971
- origStack.slice(origStackStart + 1),
+ StringPrototypeSlice(origStack, origStackStart + 1),
972
'\n'
973
);
974
// Filter all frames existing in err.stack.
0 commit comments