Skip to content

Commit

Permalink
Reorder variants
Browse files Browse the repository at this point in the history
  • Loading branch information
tyt2y3 committed Oct 6, 2022
1 parent 1225255 commit a44017f
Showing 1 changed file with 9 additions and 9 deletions.
18 changes: 9 additions & 9 deletions src/error.rs
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,15 @@ pub enum DbErr {
/// TryError
source: Box<dyn std::error::Error + Send + Sync>,
},
/// There was a problem with the database connection
#[error("Connection Error: {0}")]
Conn(#[source] RuntimeErr),
/// An operation did not execute successfully
#[error("Execution Error: {0}")]
Exec(#[source] RuntimeErr),
/// An error occurred while performing a query
#[error("Query Error: {0}")]
Query(#[source] RuntimeErr),
/// Type error: the specified type cannot be converted from u64. This is not a runtime error.
#[error("Type '{0}' cannot be converted from u64")]
ConvertFromU64(&'static str),
Expand All @@ -28,15 +37,6 @@ pub enum DbErr {
/// if the record has been correctly updated, otherwise this error will occur
#[error("Failed to get primary key from model")]
UpdateGetPrimeryKey,
/// There was a problem with the database connection
#[error("Connection Error: {0}")]
Conn(#[source] RuntimeErr),
/// An operation did not execute successfully
#[error("Execution Error: {0}")]
Exec(#[source] RuntimeErr),
/// An error occurred while performing a query
#[error("Query Error: {0}")]
Query(#[source] RuntimeErr),
/// The record was not found in the database
#[error("RecordNotFound Error: {0}")]
RecordNotFound(String),
Expand Down

0 comments on commit a44017f

Please sign in to comment.