Skip to content

Commit 6d02567

Browse files
committed
fixup weirdness
1 parent 0900074 commit 6d02567

File tree

2 files changed

+2
-9
lines changed

2 files changed

+2
-9
lines changed

lib/shim/message-shim/subscribe-consume.js

+1-4
Original file line numberDiff line numberDiff line change
@@ -219,10 +219,7 @@ function createConsumerWrapper({ shim, spec, consumer }) {
219219

220220
// Execute the original function and attempt to hook in the transaction
221221
// finish.
222-
let ret = null
223-
try {
224-
ret = shim.applySegment(consumer, tx.baseSegment, true, this, args)
225-
} catch {}
222+
let ret = shim.applySegment(consumer, tx.baseSegment, true, this, args)
226223

227224
if (shim.isPromise(ret)) {
228225
shim.logger.trace('Got a promise, attaching tx %s ending to promise', tx.id)

lib/shim/promise-shim.js

+1-5
Original file line numberDiff line numberDiff line change
@@ -416,11 +416,7 @@ function wrapHandler({ handler, index, argsLength, useAllParams, ctx, shim }) {
416416
promSegment = segment
417417
}
418418

419-
let ret = null
420-
try {
421-
ret = shim.applySegment(handler, promSegment, true, this, arguments)
422-
} catch {}
423-
419+
let ret = shim.applySegment(handler, promSegment, true, this, arguments)
424420
if (ret && typeof ret.then === 'function') {
425421
ret = ctx.handler[symbols.context].continueContext(ret)
426422
}

0 commit comments

Comments
 (0)