Skip to content

[Improvement] Don't "double-calculate" the same currency #3

@WietseWind

Description

@WietseWind

Here's an account with 19k EUR in IOU. The default currency selected in the wallet is EUR. Meaning we're looking at an IOU representation of the native asset selected in the wallet.

image

Now when the Account Worth xApp is opened:

  1. It takes the IOU value
  2. Takes the order book and checks what XRP value the IOU has
  3. Taks the XRP value and turns it into fiat value

This then results in a lower EUR value, because there's slippage (lack of liquidity)

However, if my native asset is EUR, and the IOU is EUR, I won't end up with a lower amount of EUR when looking at net worth: it should stay unconverted.

Imo, there should be one addition to the current calculations:

  • If IOU (XRPL asset code) equals user native asset code, then don't convert but use value as-is

image

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions