added proc of incorrect tokenid to tokenorders
This commit is contained in:
@@ -6974,9 +6974,13 @@ UniValue tokenorders(const UniValue& params, bool fHelp)
|
||||
throw runtime_error("tokenorders [tokenid]\n");
|
||||
if ( ensure_CCrequirements() < 0 )
|
||||
throw runtime_error("to use CC contracts, you need to launch daemon with valid -pubkey= for an address in your wallet\n");
|
||||
if ( params.size() == 1 )
|
||||
tokenid = Parseuint256((char *)params[0].get_str().c_str());
|
||||
else memset(&tokenid,0,sizeof(tokenid));
|
||||
if (params.size() == 1) {
|
||||
tokenid = Parseuint256((char *)params[0].get_str().c_str());
|
||||
if (tokenid == zeroid)
|
||||
throw runtime_error("incorrect tokenid\n");
|
||||
}
|
||||
else
|
||||
memset(&tokenid,0,sizeof(tokenid));
|
||||
return(AssetOrders(tokenid));
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user