Skip to content

Commit 04d6945

Browse files
committed
Merge branch 'main' into staging
2 parents cf16a17 + 5d3635b commit 04d6945

File tree

1 file changed

+8
-2
lines changed

1 file changed

+8
-2
lines changed

src/services/action-executor/index.ts

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -180,7 +180,10 @@ export class ActionExecutorService {
180180
})
181181
);
182182
// Verify the unlock result
183-
if (unlockResult.some((r) => !r.balanceLock || !r.newBalance)) {
183+
if (unlockResult.some((r) => !r.balanceLock)) {
184+
throw externalError("Corresponding balance lock(s) don't exist");
185+
}
186+
if (unlockResult.some((r) => !r.newBalance)) {
184187
throw externalError("Corresponding balance lock(s) already unlocked");
185188
}
186189

@@ -331,7 +334,10 @@ export class ActionExecutorService {
331334
})
332335
);
333336
// Verify the unlock result
334-
if (unlockResult.some((r) => !r.balanceLock || !r.newBalance)) {
337+
if (unlockResult.some((r) => !r.balanceLock)) {
338+
throw externalError("Corresponding balance lock(s) don't exist");
339+
}
340+
if (unlockResult.some((r) => !r.newBalance)) {
335341
throw externalError("Corresponding balance lock(s) already unlocked");
336342
}
337343

0 commit comments

Comments
 (0)