Skip to content

Commit

Permalink
split with amount pre 0.13
Browse files Browse the repository at this point in the history
  • Loading branch information
callebtc committed Dec 3, 2023
1 parent cf559ef commit f5b3f69
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions cashu/wallet/wallet.py
Original file line number Diff line number Diff line change
Expand Up @@ -452,6 +452,7 @@ async def split(

# BEGIN: backwards compatibility pre 0.13.0
split_payload.amount = outputs[0].amount
# END: backwards compatibility pre 0.13.0

# construct payload
def _splitrequest_include_fields(proofs: List[Proof]):
Expand All @@ -466,6 +467,7 @@ def _splitrequest_include_fields(proofs: List[Proof]):
return {
"outputs": ...,
"proofs": {i: proofs_include for i in range(len(proofs))},
"amount": ..., # backwards compatibility pre 0.13.0
}

resp = await self.httpx.post(
Expand Down

0 comments on commit f5b3f69

Please sign in to comment.