Skip to content

Commit

Permalink
chore: run formatter
Browse files Browse the repository at this point in the history
  • Loading branch information
hyperswitch-bot[bot] committed Nov 27, 2023
1 parent 7974007 commit 57ed4f3
Show file tree
Hide file tree
Showing 7 changed files with 28 additions and 18 deletions.
3 changes: 2 additions & 1 deletion crates/api_models/src/events/verify_connector.rs
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
use crate::verify_connector::VerifyConnectorRequest;
use common_utils::events::{ApiEventMetric, ApiEventsType};

use crate::verify_connector::VerifyConnectorRequest;

common_utils::impl_misc_api_event_type!(VerifyConnectorRequest);
2 changes: 1 addition & 1 deletion crates/api_models/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -26,5 +26,5 @@ pub mod routing;
pub mod surcharge_decision_configs;
pub mod user;
pub mod verifications;
pub mod webhooks;
pub mod verify_connector;
pub mod webhooks;
18 changes: 12 additions & 6 deletions crates/router/src/core/verify_connector.rs
Original file line number Diff line number Diff line change
@@ -1,11 +1,17 @@
use crate::{connector, core::errors, types::api, utils::OptionExt};
use api_models::enums::Connector;
use api_models::{enums::Connector, verify_connector::VerifyConnectorRequest};
use error_stack::{IntoReport, ResultExt};

use crate::types::api::verify_connector::{self as types, VerifyConnector};
use crate::utils::verify_connector as utils;
use crate::{services, AppState};
use api_models::verify_connector::VerifyConnectorRequest;
use crate::{
connector,
core::errors,
services,
types::{
api,
api::verify_connector::{self as types, VerifyConnector},
},
utils::{verify_connector as utils, OptionExt},
AppState,
};

pub async fn verify_connector_credentials(
state: AppState,
Expand Down
2 changes: 1 addition & 1 deletion crates/router/src/routes.rs
Original file line number Diff line number Diff line change
Expand Up @@ -27,9 +27,9 @@ pub mod routing;
pub mod user;
#[cfg(all(feature = "olap", feature = "kms"))]
pub mod verification;
pub mod webhooks;
#[cfg(feature = "olap")]
pub mod verify_connector;
pub mod webhooks;

pub mod locker_migration;
#[cfg(feature = "dummy_connector")]
Expand Down
7 changes: 4 additions & 3 deletions crates/router/src/routes/verify_connector.rs
Original file line number Diff line number Diff line change
@@ -1,11 +1,12 @@
use actix_web::{web, HttpRequest, HttpResponse};
use api_models::verify_connector::VerifyConnectorRequest;
use router_env::{instrument, tracing, Flow};

use super::AppState;
use crate::{
core::{api_locking, verify_connector},
services::{self, authentication as auth, authorization::permissions::Permission},
};
use actix_web::{web, HttpRequest, HttpResponse};
use api_models::verify_connector::VerifyConnectorRequest;
use router_env::{instrument, tracing, Flow};

#[instrument(skip_all, fields(flow = ?Flow::VerifyPaymentConnector))]
pub async fn payment_connector_verify(
Expand Down
11 changes: 6 additions & 5 deletions crates/router/src/types/api/verify_connector.rs
Original file line number Diff line number Diff line change
@@ -1,13 +1,14 @@
use error_stack::{IntoReport, ResultExt};
use router_env as env;

use crate::{
connector,
connector, consts,
core::errors,
services,
services::ConnectorIntegration,
types::{self, api, storage::enums as storage_enums},
AppState,
};
use error_stack::{IntoReport, ResultExt};
use router_env as env;

use crate::{consts, services::ConnectorIntegration, AppState};

#[derive(Clone, Debug)]
pub struct VerifyConnectorData {
Expand Down
3 changes: 2 additions & 1 deletion crates/router/src/utils/verify_connector.rs
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
use crate::{core::errors, types::api};
use api_models::enums::Connector;

use crate::{core::errors, types::api};

pub fn generate_card_from_details(
card_number: String,
card_exp_year: String,
Expand Down

0 comments on commit 57ed4f3

Please sign in to comment.