Callback
Callback is used to make a function call to an external contract. The external contract can perform an arbitrary logic using the bytes data
and payable value
provided by the call arguments.
One key usage for the callback is to make a token swap from a DEX contract outside of INIT.
The external contract must implement coreCallback payable
function.
It is recommended to check that msg.sender
of coreCallback
is INIT_CORE
to avoid unintended external calls from other users.
Last updated