hyperion-history-api
hyperion-history-api copied to clipboard
[BUG] Invalid 0 precision token handling /get_tokens
For 0 precision tokens missing precision field at /get_tokens response data
Example:
curl -X 'GET' \
'https://hyperion.paycash.online/v2/state/get_tokens?account=i.list' \
-H 'accept: application/json'
Logical estimate that field will be present:
{
"symbol": "LQAG",
"precision": 0,
"amount": 0,
"contract": "swap.pcash"
}
FYI @igorls looked at this a few months ago and thought it was ok

FYI @igorls looked at this a few months ago and thought it was ok
I talked before with him and it's not right. Check the contract source, asset always has a precision field and amount. Displaying precision = 0 is a correct statement. Undefined is not acceptable in this case.
@Avm07 I agree with you it's not right and I'm glad to hear that @igorls agrees now too.
Thanks for opening the issue, we will get that patched soon