mirror of
https://github.com/mCaptcha/mCaptcha.git
synced 2026-02-11 10:05:41 +00:00
user secret
This commit is contained in:
@@ -204,7 +204,9 @@ impl From<sqlx::Error> for ServiceError {
|
||||
pub fn dup_error(e: sqlx::Error, dup_error: ServiceError) -> ServiceError {
|
||||
use sqlx::error::Error;
|
||||
use std::borrow::Cow;
|
||||
// println!("sqlx:Error: {:#?}", &e);
|
||||
if let Error::Database(err) = e {
|
||||
// println!("Database Error: {:#?}", &err);
|
||||
if err.code() == Some(Cow::from("23505")) {
|
||||
dup_error
|
||||
} else {
|
||||
|
||||
Reference in New Issue
Block a user