QA Report #53
Labels
bug
Something isn't working
QA (Quality Assurance)
Assets are not at risk. State handling, function incorrect as to spec, issues with clarity, syntax
Table of Contents:
transferERC20
[L-01] Add a timelock to
transferERC20
A Malicious manager or owner could transfer any amount of token to any address.
To give more trust to users: this function should be put behind a timelock.
[L-02] Prevent accidentally burning tokens
Transferring tokens to the zero address is usually prohibited to accidentally avoid "burning" tokens by sending them to an unrecoverable zero address.
Consider adding a check to prevent accidentally burning tokens here:
[L-03] Deprecated safeApprove() function
Using this deprecated function can lead to unintended reverts and potentially the locking of funds. A deeper discussion on the deprecation of this function is in OZ issue #2219 (OpenZeppelin/openzeppelin-contracts#2219). The OpenZeppelin ERC20 safeApprove() function has been deprecated, as seen in the comments of the OpenZeppelin code.
As recommended by the OpenZeppelin comment, I suggest replacing safeApprove() with safeIncreaseAllowance() or safeDecreaseAllowance() instead:
[N-01] Missing comment section saying "public" instead of "external"
The following functions are under the
external
section:Consider adding a comment mentioning the
public
section:/* ============ Public Functions ============ */
.The text was updated successfully, but these errors were encountered: