This PR introduces the notion of phantom tokens that allow to use non-tokenized positions in integrated protocols as collateral. While phantom tokens existed before, the core was not aware of them, which ended up blocking withdrawals which are crucial for partial liquidations and some bots. Here we add support of phantom token withdrawals by prepending the simple adapter call that unwraps the position prior to withdrawing funds from a credit account.
This PR introduces the notion of phantom tokens that allow to use non-tokenized positions in integrated protocols as collateral. While phantom tokens existed before, the core was not aware of them, which ended up blocking withdrawals which are crucial for partial liquidations and some bots. Here we add support of phantom token withdrawals by prepending the simple adapter call that unwraps the position prior to withdrawing funds from a credit account.