Skip to content

Commit

Permalink
feat(async-flow): add more context to vow rejection
Browse files Browse the repository at this point in the history
  • Loading branch information
michaelfig committed Nov 1, 2024
1 parent 2dc325b commit fc1f17a
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions packages/async-flow/src/replay-membrane.js
Original file line number Diff line number Diff line change
Expand Up @@ -157,9 +157,10 @@ export const makeReplayMembraneForTesting = ({
const performCall = (hostTarget, optVerb, hostArgs, callIndex) => {
let hostResult;
try {
hostResult = optVerb
? hostTarget[optVerb](...hostArgs)
: hostTarget(...hostArgs);
hostResult =
optVerb === undefined
? hostTarget(...hostArgs)
: hostTarget[optVerb](...hostArgs);
// Try converting here just to route the error correctly
hostToGuest(hostResult, `converting ${optVerb || 'host'} result`);
} catch (hostProblem) {
Expand Down

0 comments on commit fc1f17a

Please sign in to comment.