Certain ERC20 tokens do not support zero-value token transfers and revert.
As ERC20 can be an arbitrary token, in the case when such token doesn't allow for zero amount transfers.
Vulnerability Detail
In addition to the code snippet below, you should also check the other places where there is a ERC20 transfer.
tsvetanovv
medium
ERC20 transfer zero amount can be reverted
Summary
The protocol currently uses any tokens:
Certain ERC20 tokens do not support zero-value token transfers and revert. As ERC20 can be an arbitrary token, in the case when such token doesn't allow for zero amount transfers.
Vulnerability Detail
In addition to the code snippet below, you should also check the other places where there is a ERC20 transfer.
Impact
ERC20 transfer zero amount can be reverted.
Code Snippet
Periphery.sol
Divider.sol
Tool used
Manual Review
Recommendation
Add a simple check for zero-value token transfers.