My code:
Seq([
Assert(
Txn.application_args[0] == Bytes("b")
),
App.localPut(Int(0), Bytes("T1"), Btoi(Txn.application_args[1])),
App.localPut(Int(0), Bytes("T2"), Btoi(Txn.application_args[2])),
Int(1)
])
Script:
export TOKEN1_INDEX="353"
export TOKEN2_INDEX="354"
goal app optin --app-id 310 --app-arg "str:b" --app-arg "str:${TOKEN1_INDEX}" --app-arg "str:${TOKEN2_INDEX}" --from "FKZGEODV5DEUZAEOHQKWUZL4W27LTRW45MQ6O5VDB4762EG23IRA2KCOKQ"
Result:
goal app read --app-id 310 --local --from FKZGEODV5DEUZAEOHQKWUZL4W27LTRW45MQ6O5VDB4762EG23IRA2KCOKQ
{
"T1": {
"tt": 2,
"ui": 3354931
},
"T2": {
"tt": 2,
"ui": 3354930
}
}
My expectation:
{
"T1": {
"tt": 2,
"ui": 353
},
"T2": {
"tt": 2,
"ui": 354
}
}
What am I doing wrong here? I’m new. Thanks in advance!