It is good to add a require() statement that checks the return value of token transfers, or to use something likeOpenZeppelins safeTransfer/safeTransferFrom unless one is sure the given token reverts in case of a failure. Failure to do so will cause silent failures of transfers and affect token accounting in contract.
While most places use a require or safeTransfer/safeTransferFrom, there are three missing cases in the withdrawal of staking token and rescue of arbitrary tokens sent to the FeeDistributor contract.
Reference this similar medium-severity finding from Consensys Diligence Audit of Fei Protocol.
Recommend usingsafeTransfer/safeTransferFrom or require() consistently.
- 0xKiwi (NFTX) confirmed
