Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix batch transfer NFT bug #11

Merged
merged 1 commit into from
Sep 16, 2018
Merged

Fix batch transfer NFT bug #11

merged 1 commit into from
Sep 16, 2018

Conversation

gakonst
Copy link
Contributor

@gakonst gakonst commented Sep 16, 2018

As @PhABC correctly points out in https://www.reddit.com/r/ethdev/comments/9frmcn/here_be_dragons_going_beyond_erc20_and_erc721_to/

I don't understand why tokenOwner is updated when calling the _transferFrom method, but not when calling _batchTransferFrom(). I believe this means that batch transfer will lead to incompatible outcome with ERC-721, since transferring tokens with _batchTransferFrom() does not change the tokenOwner mapping, which indicates who owns which token.

PR addresses this by updating tokenOwner if tokenType[_tokenIds[i]] == NFT

@gakonst gakonst merged commit 98adf78 into master Sep 16, 2018
@gakonst gakonst deleted the batch-transfer-nft branch September 16, 2018 16:34
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant