Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

safeApprove() is deprecated #70

Open
hats-bug-reporter bot opened this issue Nov 9, 2023 · 1 comment
Open

safeApprove() is deprecated #70

hats-bug-reporter bot opened this issue Nov 9, 2023 · 1 comment
Labels
bug Something isn't working duplicate This issue or pull request already exists invalid This doesn't seem right

Comments

@hats-bug-reporter
Copy link

Github username: @saidqayoumsadat
Submission hash (on-chain): 0x01084ca89022df2e567180e61d19471e12a796e4ee32eeda9c6cd4ed1cdac698
Severity: low

Description:
Description

Deprecated in favor of safeIncreaseAllowance() and safeDecreaseAllowance(). If only setting the initial allowance to the value that means infinite, safeIncreaseAllowance() can be used instead. The function may currently work, but if a bug is found in this version of OpenZeppelin, and the version that you're forced to upgrade to no longer has this function, you'll encounter unnecessary delays in porting and testing replacement contracts.

file: /contracts/HATClaimsManager.sol

308        _asset.safeApprove(address(_registry), 0);

https://github.com/hats-finance/hats-contracts/blob/0d6ebbde912bc272d9b310140d434ee2aacd36d3/contracts/HATClaimsManager.sol#L308

@hats-bug-reporter hats-bug-reporter bot added the bug Something isn't working label Nov 9, 2023
@jellegerbrandy
Copy link

duplicate of #17

@jellegerbrandy jellegerbrandy added duplicate This issue or pull request already exists invalid This doesn't seem right labels Nov 10, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working duplicate This issue or pull request already exists invalid This doesn't seem right
Projects
None yet
Development

No branches or pull requests

1 participant