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

refactor(StakeManager): initialMP -> bonusMP, currentMP -> totalMP #95

Merged
merged 1 commit into from
Jun 25, 2024

Conversation

0x-r4bbit
Copy link
Collaborator

After discussing this offline, we've decided that the naming of these properties was misleading. This commit performs the following changes:

  • account.initialMP becomes account.bonusMP
  • account.currentMP becomes account.totalMP

Rationale:

initialMP indicates that this is an immutable field which is not the case as in scenarios where accounts increase the lock() time, they'll also increase their bonus multiplier (initialMP).

currentMP was misleading in combination with initialMP. Really what it reflects is the total multiplier points of an account including its bonus multiplier points.

Checklist

Ensure you completed all of the steps below before submitting your pull request:

  • Added natspec comments?
  • Ran forge snapshot?
  • Ran pnpm gas-report?
  • Ran pnpm lint?
  • Ran forge test?
  • Ran pnpm verify?

After discussing this offline, we've decided that the naming of these
properties was misleading. This commit performs the following changes:

- `account.initialMP` becomes `account.bonusMP`
- `account.currentMP` becomes `account.totalMP`

Rationale:

`initialMP` indicates that this is an immutable field which is not the
case as in scenarios where accounts increase the `lock()` time, they'll
also increase their bonus multiplier (`initialMP`).

`currentMP` was misleading in combination with `initialMP`. Really what
it reflects is the total multiplier points of an account **including**
its bonus multiplier points.
@3esmit 3esmit merged commit 4a04b46 into develop Jun 25, 2024
11 checks passed
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.

2 participants