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

feat: enhance max_supply logic for Jetton supply management #24

Merged
merged 5 commits into from
Dec 31, 2024

Conversation

iamIcarus
Copy link
Collaborator

PR Summary: Update max_supply Attribute in Jetton Implementation

This PR updates the handling of the max_supply attribute to improve flexibility and enforce stricter rules.

Key Changes:

  1. Optional max_supply:

    • max_supply can be 0 to indicate unlimited supply.
  2. Minting Rules:

    • Minting stops when max_supply is reached (if not 0).
    • Unlimited minting allowed if max_supply is 0.
  3. Update Restrictions:

    • max_supply can only be set to 0 during initialization (JettonInit).
    • max_supply can only be increased via JettonSetParameter.
  4. Tests:

    • Added basic tests to verify minting behavior and max_supply constraints.

Copy link
Member

@ya7on ya7on left a comment

Choose a reason for hiding this comment

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

Hello. Awesome PR, thank you

contracts/jetton/master.tact Outdated Show resolved Hide resolved
@ya7on ya7on added this pull request to the merge queue Dec 31, 2024
Merged via the queue into supadupadao:master with commit 2a9dff0 Dec 31, 2024
2 checks passed
@iamIcarus iamIcarus linked an issue Jan 2, 2025 that may be closed by this pull request
3 tasks
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.

Update supply related attributes
2 participants