dpp/errors/consensus/fee/
fee_error.rs

1use crate::errors::consensus::fee::balance_is_not_enough_error::BalanceIsNotEnoughError;
2use crate::errors::consensus::ConsensusError;
3use bincode::{Decode, Encode};
4use thiserror::Error;
5
6use crate::errors::ProtocolError;
7use platform_serialization_derive::{PlatformDeserialize, PlatformSerialize};
8
9#[derive(
10    Error, Debug, PartialEq, Encode, Decode, PlatformSerialize, PlatformDeserialize, Clone,
11)]
12pub enum FeeError {
13    /*
14
15    DO NOT CHANGE ORDER OF VARIANTS WITHOUT INTRODUCING OF NEW VERSION
16
17    */
18    #[error(transparent)]
19    BalanceIsNotEnoughError(BalanceIsNotEnoughError),
20}
21
22impl From<FeeError> for ConsensusError {
23    fn from(error: FeeError) -> Self {
24        Self::FeeError(error)
25    }
26}