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鈥檒l occasionally send you account related emails.

Already on GitHub? Sign in to your account

Value Comparison in Require Statement ( requireMsgValue() ) #1336

Open
Hadisamadbin opened this issue Mar 2, 2024 · 1 comment
Open

Value Comparison in Require Statement ( requireMsgValue() ) #1336

Hadisamadbin opened this issue Mar 2, 2024 · 1 comment
Labels
bug Something isn't working

Comments

@Hadisamadbin
Copy link

馃悰 Bug Report

馃摑 Description

In requireMsgValue(), the comparison msg.value == _requiredValue is used to check if the value sent with the message matches the specified value. While this ensures that the exact value is sent, it might be too restrictive in some cases. Consider adding a range check or allowing a margin of error depending on the requirements of the contract.

Route

core/tests/ts-integration/contracts/context/context.sol

@Hadisamadbin Hadisamadbin added the bug Something isn't working label Mar 2, 2024
@EmilLuta
Copy link
Contributor

That's just a check, not sure how it's relevant. Please provide more information on why you find this problematic.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants