I suppose lookupAsync and lookup should remove 'contract' param. For example, my contract name is 'adv', if I use 'adv' as contract name, it will post a wrong argument to get_currency_stats like this:

curl -X POST -d '{"code":"adv","symbol":"ADV"}'

but in fact, the 'code' field must be eosio.token in most case.

Also 'lookup' function has same issue.

Once I remove contract param and set local var 'contract' to eosio.token, my webapp works fine, at least in this stage.

but the ’@‘ is referenced many times in eosjs, I'm not sure about such change is OK.

Could eosjs team help to confirm this?

function lookupAsync(symbol, contract) { assert(symbol, 'required symbol');

assert(contract, 'required contract');

if (contract === 'eosio') {
  contract = 'eosio.token';

var extendedAsset = symbol + '@' + contract;

if (cache[extendedAsset] != null) {
  return Promise.resolve(cache[extendedAsset]);

1 Answer 1


eosjs team confirmed, question could be closed now.


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.