When calling the functions, the caller needs to the pay the fee on the baseToken transfer. If the fee amount is 0, the code below would revert if the ERC20 token does not support 0 value transfer as according to https://github.com/d-xo/weird-erc20#revert-on-zero-value-transfers
Transaction revert if the baseToken does not support 0 value transfer when charging fee
https://github.com/Cyfrin/2023-07-beedle/tree/main/src/Lender.sol#L267
https://github.com/Cyfrin/2023-07-beedle/tree/main/src/Lender.sol#L563
https://github.com/Cyfrin/2023-07-beedle/tree/main/src/Lender.sol#L651
It is recommended for the protocol to check if the fee amount is 0 before performing transfer, i.e.
The contest is live. Earn rewards by submitting a finding.
This is your time to appeal against judgements on your submissions.
Appeals are being carefully reviewed by our judges.