wallet-core: get rid of AmountJson in public API

This commit is contained in:
Florian Dold 2022-11-02 18:24:50 +01:00
parent d50294f76e
commit 8442452c33
No known key found for this signature in database
GPG Key ID: D2E4F00F29D02A4B
2 changed files with 8 additions and 6 deletions

View File

@ -1614,9 +1614,9 @@ export interface GetFeeForDepositRequest {
}
export interface DepositGroupFees {
coin: AmountJson;
wire: AmountJson;
refresh: AmountJson;
coin: AmountString;
wire: AmountString;
refresh: AmountString;
}
export interface CreateDepositGroupRequest {

View File

@ -646,8 +646,10 @@ export async function getTotalFeesForDepositAmount(
});
return {
coin: Amounts.sumOrZero(total.currency, coinFee).amount,
wire: Amounts.sumOrZero(total.currency, wireFee).amount,
refresh: Amounts.sumOrZero(total.currency, refreshFee).amount,
coin: Amounts.stringify(Amounts.sumOrZero(total.currency, coinFee).amount),
wire: Amounts.stringify(Amounts.sumOrZero(total.currency, wireFee).amount),
refresh: Amounts.stringify(
Amounts.sumOrZero(total.currency, refreshFee).amount,
),
};
}