Call checkOnERC1155BatchReceived when transfering a batch of length 1 #6170
+89
−12
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Fixes #6043
Note: if a batch of size one is transfered, this still emits the "TransferSingle" event and not the "TransferBatch" event.
In order to change the event being emited, we would need to add a similar flag to
_update... and have the_updateWithAcceptanceCheckwith flag call the_updatewith flag. This would require changing all the extensions that override_updateto perform checks/tasks on all movement (that is the case of the Pausable and Supply extensions). Doing this change would likelly break many user overrides. IMO it should only be done if we do not keep a version without the flag. That would be breaking, so we need to wait for 6.0.PR Checklist
npx changeset add)