-
Notifications
You must be signed in to change notification settings - Fork 3
884: NFT batch transfer contract #2
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
base: master
Are you sure you want to change the base?
Conversation
|
This is not needed anymore :D |
|
apparently, we need it again :D @sreckosmodis can you check this PR? |
|
|
||
|
|
||
| for (uint256 index; index < recipients.length; index++) { | ||
| ERC1155Base(contractAddress).safeTransferFrom(msg.sender, recipients[index], tokenIds[index], amounts[index], ""); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Would it make sense to check the balance before the transfer?
So another require statement?
Get balance -> require to be more or equal to the amount
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
yes, good point. I will add this
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Updated
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Now there is another point of view 😄
Do we prevent all the transfers just because one of the NFTs has insufficient balance?
If we do that we should at least add the tokenId to the error message 😄
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Reverted balance checking changes
No description provided.