Skip to content

Commit

Permalink
check SupportedStandards
Browse files Browse the repository at this point in the history
  • Loading branch information
Ashuaidehao committed Oct 27, 2021
1 parent 2a3e1a5 commit 8c527f5
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions src/RpcNep11Tracker/RpcNep11Tracker.cs
Original file line number Diff line number Diff line change
Expand Up @@ -110,6 +110,7 @@ void IPersistencePlugin.OnPersist(NeoSystem system, Block block, DataCache snaps
if (!contracts.ContainsKey(transferRecord.asset))
{
var state = NativeContract.ContractManagement.GetContract(snapshot, transferRecord.asset);
if (!state.Manifest.SupportedStandards.Contains("NEP-11")) continue;
var balanceMethod = state.Manifest.Abi.GetMethod("balanceOf", 1);
var balanceMethod2 = state.Manifest.Abi.GetMethod("balanceOf", 2);
if (balanceMethod == null && balanceMethod2 == null)
Expand Down

0 comments on commit 8c527f5

Please sign in to comment.