helium / helium/react-native-helium
The values obtained for dcAccount.data[0] and dcAccount.data[1] in the getAccountFees function are null.
- Dominant language
- TypeScript
- Stars
- 15
- Forks
- 6
- PR merge metrics
- No merged PRs in 30d
Description
In the place where updating the antenna or updating the location, querying fees, the function call stack is:
useOnboarding() -> getAssertData
--> useOnboarding() -> getSolanaAssertData
--> useSonala() -> estimateMetaTxnFees
--> useSonala() -> estimateFees
--> useSonala() -> getAccountFees
Through my debugging, I found that the data format of dcAccount.data is:
```json
{
"parsed": {
"info": {
"isNative": false,
"mint": "dcuc8Amr83Wz27ZkQ2K9NS6r8zRpf1J6cvArEBDZDmm",
"owner": "Dbgjonwh5kzaQ4N9QFghC6UvFjQrMx1d9gRVf7ZWJTAT",
"state": "frozen",
"tokenAmount": {
"amount": "107000651627",
"decimals": 0,
"uiAmount": 107000651627,
"uiAmountString": "107000651627"
}
},
"type": "account"
},
"program": "spl-token",
"space": 165
}
```
However, the values extracted from dcAccount.data[0] and dcAccount.data[1] are null.
This resulted in the error 'The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type undefined.'
Contributor guide
Assessment
This issue has not been assessed yet.