Skip to content

Horizon: bug fixes #1183

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

Open
wants to merge 3 commits into
base: horizon
Choose a base branch
from
Open

Horizon: bug fixes #1183

wants to merge 3 commits into from

Conversation

tmigone
Copy link
Member

@tmigone tmigone commented Jun 5, 2025

Signed-off-by: Tomás Migone tomas@edgeandnode.com

tmigone added 2 commits June 5, 2025 12:19
Signed-off-by: Tomás Migone <tomas@edgeandnode.com>
Signed-off-by: Tomás Migone <tomas@edgeandnode.com>
@tmigone tmigone requested a review from Maikol June 5, 2025 16:00
Copy link

openzeppelin-code bot commented Jun 5, 2025

Horizon: bug fixes

Generated at commit: d89440a95ffaf9a9abfc1a6836399e3189e66e50

🚨 Report Summary

Severity Level Results
Contracts Critical
High
Medium
Low
Note
Total
2
4
0
15
39
60
Dependencies Critical
High
Medium
Low
Note
Total
0
0
0
0
0
0

For more details view the full report in OpenZeppelin Code Inspector

@@ -102,6 +102,8 @@ contract GraphTallyCollector is EIP712, GraphDirectory, Authorizable, IGraphTall
bytes calldata _data,
uint256 _tokensToCollect
) private returns (uint256) {
require(_paymentType == IGraphPayments.PaymentTypes.QueryFee, GraphTallyCollectorInvalidPaymentType(_paymentType));
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks a little strange that we take an input where we only accept one value, maybe we should get rid of the parameter and rename this to _collectQueryFees() ? Changes might be more involved so if we want to keep things minimal this sounds good.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

you could move this check to collect() and remove the param in this fn. That being said, this is already being audited...

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Agree that it looks weird in this particular case but the reason is because it's part of the IPaymentsCollector interface, for a generic collector we need the payment type as a parameter because we might have collectors that process multiple types of payments.

Signed-off-by: Tomás Migone <tomas@edgeandnode.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants