chore: move RouterData Request types to hyperswitch_domain_models crate (#4723)

Co-authored-by: hyperswitch-bot[bot] <148525504+hyperswitch-bot[bot]@users.noreply.github.com>
This commit is contained in:
Hrithikesh
2024-05-23 15:48:51 +05:30
committed by GitHub
parent 5e5eb5fbae
commit ae77373b4c
38 changed files with 2397 additions and 1943 deletions

View File

@ -1,6 +1,7 @@
pub use common_utils::errors::{ParsingError, ValidationError};
#[cfg(feature = "email")]
use external_services::email::EmailError;
use hyperswitch_domain_models::errors::api_error_response::ApiErrorResponse;
pub use redis_interface::errors::RedisError;
pub use storage_impl::errors::ApplicationError;
use storage_impl::errors::StorageError;
@ -88,6 +89,12 @@ impl<T: PTError> From<T> for ProcessTrackerError {
}
}
impl PTError for ApiErrorResponse {
fn to_pt_error(&self) -> ProcessTrackerError {
ProcessTrackerError::EApiErrorResponse
}
}
impl<T: PTError + std::fmt::Debug + std::fmt::Display> From<error_stack::Report<T>>
for ProcessTrackerError
{