MetaMask / metamask-extension

:globe_with_meridians: :electric_plug: The MetaMask browser extension enables browsing Ethereum blockchain enabled websites
https://metamask.io
Other
11.57k stars 4.73k forks source link

[Bug]: Contract Interactions - Triggering mint functions displays the mint recipient instead of the contract address in the To header #24561

Open seaona opened 2 weeks ago

seaona commented 2 weeks ago

Describe the bug

Whenever we are interacting with a contract, if I trigger the mint function function mint(address to, uint256 amount) with signature 0x40c10f19we see how the recipient is now the address to whom we are minting tokens to, instead of the usual contract address.

Expected behavior

We should see the contract address as recipient, like we do with the rest of contract interactions, that don't have a custom screen.

Screenshots/Recordings

Screenshot from 2024-05-16 11-05-18

https://github.com/MetaMask/metamask-extension/assets/54408225/855d705c-818a-4d5d-b6e3-d7d26c3045ed

Steps to reproduce

  1. Select mainnet
  2. Go to https://etherscan.io/token/0x6b175474e89094c44da98b954eedeac495271d0f#writeContract
  3. Connect MM
  4. Trigger a mint
  5. See how the recipient is not the contract address but the address you input in the mint function

Error messages or log output

No response

Version

11.15.4 prod (maybe earlier)

Build type

None

Browser

Chrome

Operating system

Linux

Hardware wallet

No response

Additional context

No response

Severity

No response