mpl_hybrid/generated/errors/
mpl_hybrid.rs1use num_derive::FromPrimitive;
9use thiserror::Error;
10
11#[derive(Clone, Debug, Eq, Error, FromPrimitive, PartialEq)]
12pub enum MplHybridError {
13 #[error("Invalid Collection")]
15 InvalidCollection,
16 #[error("Collection Authority does not match signer")]
18 InvalidCollectionAuthority,
19 #[error("Error in the randomness")]
21 RandomnessError,
22 #[error("Invalid Fee Constant Wallet")]
24 InvalidConstantFeeWallet,
25 #[error("Invalid Project Fee Wallet")]
27 InvalidProjectFeeWallet,
28 #[error("Invalid SlotHash Program Account")]
30 InvalidSlotHash,
31 #[error("Invalid MPL CORE Program Account")]
33 InvalidMplCore,
34 #[error("Invalid Collection Account")]
36 InvalidCollectionAccount,
37 #[error("Invalid Asset Account")]
39 InvalidAssetAccount,
40 #[error("Max must be greater than Min")]
42 MaxMustBeGreaterThanMin,
43 #[error("Invalid Mint Account")]
45 InvalidMintAccount,
46}
47
48impl solana_program::program_error::PrintProgramError for MplHybridError {
49 fn print<E>(&self) {
50 solana_program::msg!(&self.to_string());
51 }
52}