Unsafe transfer in ERC1155

Hey everyone!

I'm interested in making an unsafe transfer function for a 1155 NFT. (I can go into the details of why, the short version would be gas savings on a push-style airdrop.) That would mean getting rid of all of the wonderful and wise checks OZ makes in _beforeTokenTransfer and also not checking for 1155Receiver on the other end.

(If it makes anyone feel any better, the function will be locked with onlyOwner, the owner being the only one who needs this function and reasonably educated about the risks.)

The problem is that _mint updates the _balances mapping, which is private and in the ERC1155 contract, so I have no good way of getting to it (unless there's some Solidity wizardry that I don't know about). Working with a different balances system would then mean needing to rewrite all the transfer and mint functions, and at that point it would basically be it's own 1155 independent of OZ.

Is there any way to get this granular a level of customization on an OZ contract?

Sorry, our ERC1155 implementation doesn't allow you to break the ERC1155 spec, and so it forces you to run the receiver hook.

If you want to do something different to the spec you will need to fork the code and make the changes.