refactor(router): remove admin v2 intermediate features (#5780)

Co-authored-by: Narayan Bhat <narayan.bhat@juspay.in>
Co-authored-by: Aprabhat19 <amishaprabhat@gmail.com>
Co-authored-by: hyperswitch-bot[bot] <148525504+hyperswitch-bot[bot]@users.noreply.github.com>
This commit is contained in:
Sai Harsha Vardhan
2024-09-04 13:58:05 +05:30
committed by GitHub
parent c84af20ec1
commit b853226120
71 changed files with 458 additions and 1351 deletions

View File

@ -134,10 +134,7 @@ pub async fn create_link_token(
.and_then(|address| address.country)
.map(|country| country.to_string());
#[cfg(all(
any(feature = "v1", feature = "v2"),
not(feature = "merchant_connector_account_v2")
))]
#[cfg(feature = "v1")]
let merchant_connector_account = state
.store
.find_by_merchant_connector_account_merchant_id_merchant_connector_id(
@ -151,7 +148,7 @@ pub async fn create_link_token(
id: merchant_account.get_id().get_string_repr().to_owned(),
})?;
#[cfg(all(feature = "v2", feature = "merchant_connector_account_v2"))]
#[cfg(feature = "v2")]
let merchant_connector_account = {
let _ = billing_country;
todo!()
@ -239,10 +236,7 @@ pub async fn exchange_token_core(
let connector = PaymentAuthConnectorData::get_connector_by_name(connector_name)?;
#[cfg(all(
any(feature = "v1", feature = "v2"),
not(feature = "merchant_connector_account_v2")
))]
#[cfg(feature = "v1")]
let merchant_connector_account = state
.store
.find_by_merchant_connector_account_merchant_id_merchant_connector_id(
@ -256,7 +250,7 @@ pub async fn exchange_token_core(
id: merchant_account.get_id().get_string_repr().to_owned(),
})?;
#[cfg(all(feature = "v2", feature = "merchant_connector_account_v2"))]
#[cfg(feature = "v2")]
let merchant_connector_account: domain::MerchantConnectorAccount = {
let _ = merchant_account;
let _ = connector;
@ -740,10 +734,7 @@ pub async fn retrieve_payment_method_from_auth_service(
.await
.to_not_found_response(ApiErrorResponse::MerchantAccountNotFound)?;
#[cfg(all(
any(feature = "v1", feature = "v2"),
not(feature = "merchant_connector_account_v2")
))]
#[cfg(feature = "v1")]
let mca = db
.find_by_merchant_connector_account_merchant_id_merchant_connector_id(
key_manager_state,
@ -764,7 +755,7 @@ pub async fn retrieve_payment_method_from_auth_service(
"error while fetching merchant_connector_account from merchant_id and connector name",
)?;
#[cfg(all(feature = "v2", feature = "merchant_connector_account_v2"))]
#[cfg(feature = "v2")]
let mca = {
let _ = merchant_account;
let _ = connector;