From 2743eee044edfd3dafc012e31f60ecf4ee0ce30f Mon Sep 17 00:00:00 2001 From: Amir Bandeali Date: Thu, 26 Jul 2018 16:30:44 -0700 Subject: Update checking for erc721 existence --- packages/contracts/test/utils/erc721_wrapper.ts | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) (limited to 'packages/contracts') diff --git a/packages/contracts/test/utils/erc721_wrapper.ts b/packages/contracts/test/utils/erc721_wrapper.ts index d023b4d02..0c12130a3 100644 --- a/packages/contracts/test/utils/erc721_wrapper.ts +++ b/packages/contracts/test/utils/erc721_wrapper.ts @@ -35,8 +35,6 @@ export class ERC721Wrapper { artifacts.DummyERC721Token, this._provider, txDefaults, - constants.DUMMY_TOKEN_NAME, - constants.DUMMY_TOKEN_SYMBOL, ), ); } @@ -81,7 +79,8 @@ export class ERC721Wrapper { } public async doesTokenExistAsync(tokenAddress: string, tokenId: BigNumber): Promise { const tokenContract = this._getTokenContractFromAssetData(tokenAddress); - const doesExist = await tokenContract.exists.callAsync(tokenId); + const owner = await tokenContract.ownerOf.callAsync(tokenId); + const doesExist = owner !== constants.NULL_ADDRESS; return doesExist; } public async approveProxyAsync(tokenAddress: string, tokenId: BigNumber): Promise { -- cgit v1.2.3