|
@@ -147,7 +147,8 @@ contract ERC721Token is SupportsInterfaceWithLookup, ERC721BasicToken, ERC721 {
|
|
|
uint256 lastToken = ownedTokens[_from][lastTokenIndex];
|
|
|
|
|
|
ownedTokens[_from][tokenIndex] = lastToken;
|
|
|
- ownedTokens[_from].length--; // This also deletes the contents at the last position of the array
|
|
|
+ ownedTokens[_from].length--;
|
|
|
+ // ^ This also deletes the contents at the last position of the array
|
|
|
|
|
|
// Note that this will handle single-element arrays. In that case, both tokenIndex and lastTokenIndex are going to
|
|
|
// be zero. Then we can make sure that we will remove _tokenId from the ownedTokens list since we are first swapping
|