1use cosmwasm_std::{Addr, StdError};
2use cw_utils::{self, PaymentError};
3use thiserror::Error;
4
5#[derive(Error, Debug, PartialEq)]
6pub enum ContractError {
7 #[error("{0}")]
8 Std(#[from] StdError),
9
10 #[error("{0}")]
11 PaymentError(#[from] PaymentError),
12
13 #[error("Contract has no funds")]
14 NoFunds {},
15
16 #[error("Insufficient Funds for Instantiate")]
17 InsufficientFundsInstantiate {},
18
19 #[error("Airdrop Amount Too Small")]
20 AirdropTooSmall {},
21
22 #[error("Airdrop Amount Too Big")]
23 AirdropTooBig {},
24
25 #[error("Invalid reply ID")]
26 InvalidReplyID {},
27
28 #[error("Unauthorized admin, sender is {sender}")]
29 Unauthorized { sender: Addr },
30
31 #[error("Reply error")]
32 ReplyOnSuccess {},
33
34 #[error("Whitelist contract has not been set")]
35 WhitelistContractNotSet {},
36
37 #[error("Minter already set")]
38 MinterAlreadySet {},
39
40 #[error("Address {address} is not eligible")]
41 AddressNotEligible { address: String },
42
43 #[error("Address {address} has already claimed all available mints")]
44 MintCountReached { address: String },
45
46 #[error("Collection Whitelist on Minter contract has not been set")]
47 CollectionWhitelistMinterNotSet {},
48
49 #[error("Plaintext message must contain `{{wallet}}` string")]
50 PlaintextMsgNoWallet {},
51
52 #[error("Plaintext message is too long")]
53 PlaintextTooLong {},
54}