Skip to content

Commit

Permalink
fix: payout send handler
Browse files Browse the repository at this point in the history
  • Loading branch information
fmorency committed Feb 12, 2025
1 parent 18dc41c commit c3a9749
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 6 deletions.
2 changes: 1 addition & 1 deletion bun.lock
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
"@liftedinit/manifestjs": "0.0.1-rc.1",
"@react-three/drei": "^9.114.0",
"@react-three/fiber": "^8.17.8",
"@skip-go/client": "^0.16.8",
"@skip-go/client": "^0.16.9",
"@tanstack/react-query": "^5.55.0",
"@tanstack/react-query-devtools": "^5.55.0",
"@types/file-saver": "^2.0.7",
Expand Down
14 changes: 9 additions & 5 deletions components/bank/handlers/manifest/msgPayoutHandler.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -28,11 +28,15 @@ const createSendMessage = (
</span>
);
const recipient =
pairs.length > 1
? `distributed across ${pairs.length} addresses`
: pairs?.[0]?.address
? `to ${(<TruncatedAddressWithCopy address={pairs[0].address} slice={24} />)}`
: 'an unknown address';
pairs.length > 1 ? (
`distributed across ${pairs.length} addresses`
) : pairs?.[0]?.address ? (
<>
to <TruncatedAddressWithCopy address={pairs[0].address} slice={24} />{' '}
</>
) : (
'an unknown address'
);
const message = format(template, coloredAmount, recipient);
return <span className="flex gap-1">{message}</span>;
};
Expand Down

0 comments on commit c3a9749

Please sign in to comment.