File tree Expand file tree Collapse file tree 1 file changed +5
-7
lines changed Expand file tree Collapse file tree 1 file changed +5
-7
lines changed Original file line number Diff line number Diff line change @@ -408,6 +408,7 @@ Raven.prototype = {
408408 * @return {Raven }
409409 */
410410 captureException : function ( ex , options ) {
411+ options = objectMerge ( { trimHeadFrames : 0 } , options ? options : { } ) ;
411412 // Cases for sending ex as a message, rather than an exception
412413 var isNotError = ! isError ( ex ) ;
413414 var isNotErrorEvent = ! isErrorEvent ( ex ) ;
@@ -416,13 +417,10 @@ Raven.prototype = {
416417 if ( ( isNotError && isNotErrorEvent ) || isErrorEventWithoutError ) {
417418 return this . captureMessage (
418419 ex ,
419- objectMerge (
420- {
421- trimHeadFrames : 1 ,
422- stacktrace : true // if we fall back to captureMessage, default to attempting a new trace
423- } ,
424- options
425- )
420+ objectMerge ( options , {
421+ stacktrace : true , // if we fall back to captureMessage, default to attempting a new trace
422+ trimHeadFrames : options . trimHeadFrames + 1
423+ } )
426424 ) ;
427425 }
428426
You can’t perform that action at this time.
0 commit comments