mirror of
https://github.com/d0zingcat/ore.git
synced 2026-05-14 07:26:51 +00:00
error macro
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
use num_enum::IntoPrimitive;
|
||||
use solana_program::program_error::ProgramError;
|
||||
use ore_utils::*;
|
||||
use thiserror::Error;
|
||||
|
||||
#[derive(Debug, Error, Clone, Copy, PartialEq, Eq, IntoPrimitive)]
|
||||
@@ -23,8 +23,4 @@ pub enum OreError {
|
||||
AuthFailed = 7,
|
||||
}
|
||||
|
||||
impl From<OreError> for ProgramError {
|
||||
fn from(e: OreError) -> Self {
|
||||
ProgramError::Custom(e as u32)
|
||||
}
|
||||
}
|
||||
error!(OreError);
|
||||
|
||||
Reference in New Issue
Block a user