You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
i think it's better UX to have granular methods, instead of a single setter with boolean arguments where one argument can easily be sent in bad order and confusing for caller.
setApprovals(0x01, true, false) can have different consequences than setApprovals(0x01, false, true)
potentially error prone, i prefer explicit methods.
storming0x
changed the title
Improve UX around setApprovals for delegating actions
[Gauge] - Improve UX around setApprovals for delegating actions
Jun 20, 2022
veYFI/contracts/Gauge.sol
Line 537 in bff7cc2
i think it's better UX to have granular methods, instead of a single setter with boolean arguments where one argument can easily be sent in bad order and confusing for caller.
setApprovals(0x01, true, false)
can have different consequences thansetApprovals(0x01, false, true)
potentially error prone, i prefer explicit methods.
enableClaimingFrom(address)
.disableClaimingFrom(address)
enableLockingFrom(address)
.disableLockingFrom(address)
less arguments and makes the side effect explicit avoiding potential oops factor
The text was updated successfully, but these errors were encountered: