From 4db65104f1d115914a88297f9782f9abdcb3cad1 Mon Sep 17 00:00:00 2001 From: 0xPatrick Date: Mon, 9 Dec 2024 13:58:33 -0500 Subject: [PATCH] chore: resolve `withdrawToSeat` TODO with comment --- packages/fast-usdc/src/exos/settler.js | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/packages/fast-usdc/src/exos/settler.js b/packages/fast-usdc/src/exos/settler.js index 035c288cabd..31020e8989f 100644 --- a/packages/fast-usdc/src/exos/settler.js +++ b/packages/fast-usdc/src/exos/settler.js @@ -230,13 +230,12 @@ export const prepareSettler = ( const split = calculateSplit(received); log('disbursing', split); - // TODO: what if this throws? - // arguably, it cannot. Even if deposits - // and notifications get out of order, - // we don't ever withdraw more than has been deposited. + // If this throws, which arguably can't occur since we don't ever + // withdraw more than has been deposited, funds will remain in the + // `settlementAccount`. A remediation can occur in a future upgrade. await vowTools.when( withdrawToSeat( - // @ts-expect-error Vow vs. Promise stuff. TODO: is this OK??? + // @ts-expect-error LocalAccountMethods vs OrchestrationAccount settlementAccount, settlingSeat, harden({ In: received }),