Skip to content

Conversation

@dbadoy
Copy link
Member

@dbadoy dbadoy commented May 27, 2025

Previously, fetchReward was performed on lastStage, and when addStage was called, the rewards, amounts, and proofs information was stored at lastStage + 1, which was contextually inconsistent.

In this PR, modified it so that lastStage + 1 (i.e., currentStage) is passed as a parameter instead.

@dbadoy dbadoy marked this pull request as draft May 27, 2025 07:29
@codecov
Copy link

codecov bot commented May 27, 2025

Codecov Report

Attention: Patch coverage is 85.71429% with 2 lines in your changes missing coverage. Please review.

Files with missing lines Patch % Lines
src/hub/reward/MerkleRewardDistributor.sol 85.71% 2 Missing ⚠️

📢 Thoughts on this report? Let us know!

@dbadoy dbadoy marked this pull request as ready for review May 27, 2025 07:30
Copy link
Member

@byeongsu-hong byeongsu-hong left a comment

Choose a reason for hiding this comment

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

We need to initialize $.lastStage to zero to make it clearly

@dbadoy dbadoy requested a review from byeongsu-hong May 27, 2025 15:39
@dbadoy dbadoy merged commit a039f12 into main May 28, 2025
2 checks passed
@dbadoy dbadoy deleted the fix/merkle-reward-distributor branch May 28, 2025 08:00
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