Skip to content

Referral mints #8

@vikiival

Description

@vikiival

Context

We would like a way for people to obtain a small reward for referring someone to mint.

Task

  1. create a new function called function mintWithReferral(address to, uint256 quantity, address referrer) public payable (basically functionaliy of safeBachMint)
  2. with the payment splitter enabled - the referral amount will be deducted from the owner's part (therefore _receiver's part is untouched)
  3. referral amount is equal to royalty price - that is calculated with royaltyInfo
  4. if referrer is equal to _receiver || address(0) referral bounty cannot be applied (do not throw error just code should ignore that)
  5. if royaltyInfo also returns 0 the referral bounty cannot be applied.
  6. Extend tests to ensure the stuff works

Links

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions