diff --git a/Libraries/promiseRejectionTrackingOptions.js b/Libraries/promiseRejectionTrackingOptions.js index fbdcd4abf88f91..3973bb49455185 100644 --- a/Libraries/promiseRejectionTrackingOptions.js +++ b/Libraries/promiseRejectionTrackingOptions.js @@ -36,6 +36,11 @@ let rejectionTrackingOptions: $Call = { ? rejection : JSON.stringify((rejection: $FlowFixMe)); } + // It could although this object is not a standard error, it still has stack information to unwind + // $FlowFixMe ignore types just check if stack is there + if (rejection.stack && typeof rejection.stack === 'string') { + stack = rejection.stack; + } } const warning = `Possible unhandled promise rejection (id: ${id}):\n${