lint
This commit is contained in:
parent
70d5c09d3e
commit
c3a7d1646c
@ -15,9 +15,7 @@ use axum::{
|
||||
Extension, Json, TypedHeader,
|
||||
};
|
||||
use axum_macros::debug_handler;
|
||||
use check_if_email_exists::{
|
||||
check_email, CheckEmailInput, CheckEmailInputProxy, CheckEmailOutput, Reachable,
|
||||
};
|
||||
use check_if_email_exists::{check_email, CheckEmailInput, Reachable};
|
||||
use entities;
|
||||
use entities::user;
|
||||
use migration::sea_orm::{self, ActiveModelTrait};
|
||||
@ -66,17 +64,12 @@ pub async fn user_post(
|
||||
let check_email_input = CheckEmailInput::new(x.clone());
|
||||
// Verify this input, using async/await syntax.
|
||||
let result = check_email(&check_email_input).await;
|
||||
match result.is_reachable {
|
||||
Reachable::Invalid => {
|
||||
return Err(Web3ProxyError::BadRequest(
|
||||
"The e-mail address you provided seems invalid".into(),
|
||||
));
|
||||
}
|
||||
// Let's be very chill about the validity of e-mails, and only error if the Syntax / SMPT / MX does not work
|
||||
// Reachable::Safe => {}
|
||||
// Reachable::Unknown => {}
|
||||
// Reachable::Risky => {}
|
||||
_ => {}
|
||||
|
||||
// Let's be very chill about the validity of e-mails, and only error if the Syntax / SMPT / MX does not work
|
||||
if let Reachable::Invalid = result.is_reachable {
|
||||
return Err(Web3ProxyError::BadRequest(
|
||||
"The e-mail address you provided seems invalid".into(),
|
||||
));
|
||||
}
|
||||
|
||||
// TODO: do some basic validation
|
||||
|
@ -12,9 +12,8 @@ use axum::{
|
||||
use axum_client_ip::InsecureClientIp;
|
||||
use axum_macros::debug_handler;
|
||||
use entities::{balance, increase_on_chain_balance_receipt, rpc_key, user};
|
||||
use ethbloom::Input as BloomInput;
|
||||
use ethers::abi::AbiEncode;
|
||||
use ethers::types::{Address, TransactionReceipt, ValueOrArray, H256};
|
||||
use ethers::types::{Address, TransactionReceipt, H256};
|
||||
use hashbrown::HashMap;
|
||||
use http::StatusCode;
|
||||
use log::{debug, info, trace};
|
||||
|
@ -19,7 +19,6 @@ use itertools::Itertools;
|
||||
use migration::sea_orm::{
|
||||
self, ActiveModelTrait, ColumnTrait, EntityTrait, IntoActiveModel, QueryFilter, TryIntoModel,
|
||||
};
|
||||
use migration::LockType;
|
||||
use serde::Deserialize;
|
||||
use serde_json::json;
|
||||
use std::sync::Arc;
|
||||
|
@ -26,7 +26,6 @@ use migration::sea_orm::TransactionTrait;
|
||||
use serde_json::json;
|
||||
use std::sync::Arc;
|
||||
use ulid::{self, Ulid};
|
||||
use uuid::Uuid;
|
||||
|
||||
pub async fn get_keys_as_subuser(
|
||||
Extension(app): Extension<Arc<Web3ProxyApp>>,
|
||||
|
Loading…
Reference in New Issue
Block a user