keep-starknet-strange / unruggable.meme

☣️ A framework for building safer memecoins 💸
https://unruggable.meme
MIT License
141 stars 94 forks source link

feat: implement maximum holders before launch safeguard #4

Closed AbdelStark closed 10 months ago

AbdelStark commented 11 months ago

Issue: Implement Maximum Holders Safeguard in Smart Contract

Description

This issue aims to implement a safeguard in the smart contract to limit the number of holders before the launch of the memecoin. This is crucial to prevent the contract from being launched with an excessively large number of holders, which could potentially lead to issues in distribution and management.

Requirements

  1. Max Holders Constant: Define a constant, MAX_HOLDERS_BEFORE_LAUNCH, set to 10. This will be the maximum number of holders allowed before the memecoin is launched.
  2. Tracking Launch Status: Implement a boolean variable in the contract's storage to track whether the memecoin has been launched. This variable should be initialized to false at deployment and set to true when the launch_memecoin function is called.
  3. Holder Count Logic: Implement logic to track the number of holders. This tracking should only be active before the launch of the token. After the launch, stop tracking the number of holders to optimize for on-chain operation costs.
  4. Transfer Restriction: If the maximum number of holders (10) is reached before the token is launched, disable transfers. Ensure that transfers are only re-enabled after the token launch.

Implementation Notes

Additional Context

The implementation of this safeguard is a preventive measure to maintain the integrity of the token distribution process and to ensure a fair and manageable launch. Post-launch, the holder count tracking will be discontinued to reduce the cost and complexity of on-chain operations.


This GitHub issue outlines the task of implementing a safeguard in the Unruggable Memecoin smart contract to limit the number of holders before the launch and to manage the launch status efficiently.

credence0x commented 11 months ago

i can take this

AbdelStark commented 11 months ago

credence0x

ok assigned to you, can you please join the telegram group for coordination it will be easier. Glad to have you onboard on the project and starting to contribute mate 💪