1 | ;
|
2 |
|
3 | var go = module.exports = function (err, nlines) {
|
4 |
|
5 | var relevant = err.stack.split('\n').slice(0, nlines);
|
6 |
|
7 | // remove location from last trace which points to our test file
|
8 | // that location will change all the time, so we don't want it
|
9 | var last = relevant.pop();
|
10 | relevant.push(last.split(':')[0]);
|
11 | return relevant;
|
12 | };
|