From 34828032ac2d305fee73d5758fe361476c4c1533 Mon Sep 17 00:00:00 2001 From: Dirkjan Ochtman Date: Thu, 2 Dec 2021 14:16:03 +0100 Subject: [PATCH] Remove unnecessary type alias --- epp-client/src/contact/delete.rs | 4 ++-- epp-client/src/contact/update.rs | 4 ++-- epp-client/src/domain/delete.rs | 4 ++-- epp-client/src/domain/transfer.rs | 8 ++++---- epp-client/src/domain/update.rs | 4 ++-- epp-client/src/host/delete.rs | 4 ++-- epp-client/src/host/update.rs | 4 ++-- epp-client/src/login.rs | 4 ++-- epp-client/src/logout.rs | 4 ++-- epp-client/src/response.rs | 3 --- 10 files changed, 20 insertions(+), 23 deletions(-) diff --git a/epp-client/src/contact/delete.rs b/epp-client/src/contact/delete.rs index bccfd3f..8172c8b 100644 --- a/epp-client/src/contact/delete.rs +++ b/epp-client/src/contact/delete.rs @@ -5,7 +5,7 @@ use epp_client_macros::*; use super::XMLNS; use crate::common::{ElementName, NoExtension, StringValue}; use crate::request::{EppExtension, EppRequest}; -use crate::response::EppCommandResponse; +use crate::response::ResponseStatus; use serde::{Deserialize, Serialize}; #[derive(Debug)] @@ -16,7 +16,7 @@ pub struct ContactDelete { impl EppRequest for ContactDelete { type Input = ContactDeleteRequest; - type Output = EppCommandResponse; + type Output = ResponseStatus; fn into_parts(self) -> (Self::Input, Option) { (self.request, self.extension) diff --git a/epp-client/src/contact/update.rs b/epp-client/src/contact/update.rs index 465112b..9064c33 100644 --- a/epp-client/src/contact/update.rs +++ b/epp-client/src/contact/update.rs @@ -7,7 +7,7 @@ use crate::common::{ ContactAuthInfo, ContactStatus, ElementName, NoExtension, Phone, PostalInfo, StringValue, }; use crate::request::{EppExtension, EppRequest}; -use crate::response::EppCommandResponse; +use crate::response::ResponseStatus; use serde::{Deserialize, Serialize}; #[derive(Debug)] @@ -18,7 +18,7 @@ pub struct ContactUpdate { impl EppRequest for ContactUpdate { type Input = ContactUpdateRequest; - type Output = EppCommandResponse; + type Output = ResponseStatus; fn into_parts(self) -> (Self::Input, Option) { (self.request, self.extension) diff --git a/epp-client/src/domain/delete.rs b/epp-client/src/domain/delete.rs index 0d67fff..fd3166e 100644 --- a/epp-client/src/domain/delete.rs +++ b/epp-client/src/domain/delete.rs @@ -5,7 +5,7 @@ use epp_client_macros::*; use super::XMLNS; use crate::common::{ElementName, NoExtension, StringValue}; use crate::request::{EppExtension, EppRequest}; -use crate::response::EppCommandResponse; +use crate::response::ResponseStatus; use serde::{Deserialize, Serialize}; #[derive(Debug)] @@ -16,7 +16,7 @@ pub struct DomainDelete { impl EppRequest for DomainDelete { type Input = DomainDeleteRequest; - type Output = EppCommandResponse; + type Output = ResponseStatus; fn into_parts(self) -> (Self::Input, Option) { (self.request, self.extension) diff --git a/epp-client/src/domain/transfer.rs b/epp-client/src/domain/transfer.rs index b5d2f0a..409d208 100644 --- a/epp-client/src/domain/transfer.rs +++ b/epp-client/src/domain/transfer.rs @@ -5,7 +5,7 @@ use epp_client_macros::*; use super::XMLNS; use crate::common::{DomainAuthInfo, ElementName, NoExtension, Period, StringValue}; use crate::request::{EppExtension, EppRequest}; -use crate::response::EppCommandResponse; +use crate::response::ResponseStatus; use serde::{Deserialize, Serialize}; #[derive(Debug)] @@ -31,7 +31,7 @@ pub struct DomainTransferApprove { impl EppRequest for DomainTransferApprove { type Input = DomainTransferReq; - type Output = EppCommandResponse; + type Output = ResponseStatus; fn into_parts(self) -> (Self::Input, Option) { (self.request, self.extension) @@ -46,7 +46,7 @@ pub struct DomainTransferReject { impl EppRequest for DomainTransferReject { type Input = DomainTransferReq; - type Output = EppCommandResponse; + type Output = ResponseStatus; fn into_parts(self) -> (Self::Input, Option) { (self.request, self.extension) @@ -61,7 +61,7 @@ pub struct DomainTransferCancel { impl EppRequest for DomainTransferCancel { type Input = DomainTransferReq; - type Output = EppCommandResponse; + type Output = ResponseStatus; fn into_parts(self) -> (Self::Input, Option) { (self.request, self.extension) diff --git a/epp-client/src/domain/update.rs b/epp-client/src/domain/update.rs index af6ea78..1219ddd 100644 --- a/epp-client/src/domain/update.rs +++ b/epp-client/src/domain/update.rs @@ -12,7 +12,7 @@ use crate::{ use super::XMLNS; -use crate::response::EppCommandResponse; +use crate::response::ResponseStatus; use serde::{Deserialize, Serialize}; #[derive(Debug)] @@ -23,7 +23,7 @@ pub struct DomainUpdate { impl EppRequest for DomainUpdate { type Input = DomainUpdateRequest; - type Output = EppCommandResponse; + type Output = ResponseStatus; fn into_parts(self) -> (Self::Input, Option) { (self.request, self.extension) diff --git a/epp-client/src/host/delete.rs b/epp-client/src/host/delete.rs index 9da5d11..c05eecd 100644 --- a/epp-client/src/host/delete.rs +++ b/epp-client/src/host/delete.rs @@ -5,7 +5,7 @@ use epp_client_macros::*; use super::XMLNS; use crate::common::{ElementName, NoExtension, StringValue}; use crate::request::{EppExtension, EppRequest}; -use crate::response::EppCommandResponse; +use crate::response::ResponseStatus; use serde::{Deserialize, Serialize}; #[derive(Debug)] @@ -16,7 +16,7 @@ pub struct HostDelete { impl EppRequest for HostDelete { type Input = HostDeleteRequest; - type Output = EppCommandResponse; + type Output = ResponseStatus; fn into_parts(self) -> (Self::Input, Option) { (self.request, self.extension) diff --git a/epp-client/src/host/update.rs b/epp-client/src/host/update.rs index 360742d..f2c36a8 100644 --- a/epp-client/src/host/update.rs +++ b/epp-client/src/host/update.rs @@ -5,7 +5,7 @@ use epp_client_macros::*; use super::XMLNS; use crate::common::{ElementName, HostAddr, HostStatus, NoExtension, StringValue}; use crate::request::{EppExtension, EppRequest}; -use crate::response::EppCommandResponse; +use crate::response::ResponseStatus; use serde::{Deserialize, Serialize}; #[derive(Debug)] @@ -16,7 +16,7 @@ pub struct HostUpdate { impl EppRequest for HostUpdate { type Input = HostUpdateRequest; - type Output = EppCommandResponse; + type Output = ResponseStatus; fn into_parts(self) -> (Self::Input, Option) { (self.request, self.extension) diff --git a/epp-client/src/login.rs b/epp-client/src/login.rs index 23e5cb5..067f740 100644 --- a/epp-client/src/login.rs +++ b/epp-client/src/login.rs @@ -7,7 +7,7 @@ use crate::{ common::{ElementName, NoExtension, Options, ServiceExtension, Services, StringValue}, contact, domain, host, request::{EppExtension, EppRequest, EPP_LANG, EPP_VERSION}, - response::EppCommandResponse, + response::ResponseStatus, }; #[derive(Debug)] @@ -18,7 +18,7 @@ pub struct Login { impl EppRequest for Login { type Input = LoginRequest; - type Output = EppCommandResponse; + type Output = ResponseStatus; fn into_parts(self) -> (Self::Input, Option) { (self.request, self.extension) diff --git a/epp-client/src/logout.rs b/epp-client/src/logout.rs index b7d3f6f..ae507b5 100644 --- a/epp-client/src/logout.rs +++ b/epp-client/src/logout.rs @@ -6,7 +6,7 @@ use serde::{Deserialize, Serialize}; use crate::{ common::{ElementName, NoExtension}, request::{EppExtension, EppRequest}, - response::EppCommandResponse, + response::ResponseStatus, }; #[derive(Debug)] @@ -17,7 +17,7 @@ pub struct Logout { impl EppRequest for Logout { type Input = LogoutRequest; - type Output = EppCommandResponse; + type Output = ResponseStatus; fn into_parts(self) -> (Self::Input, Option) { (self.request, self.extension) diff --git a/epp-client/src/response.rs b/epp-client/src/response.rs index e83dc62..4fcd745 100644 --- a/epp-client/src/response.rs +++ b/epp-client/src/response.rs @@ -6,9 +6,6 @@ use std::fmt::Debug; use crate::common::{ElementName, Extension, StringValue}; -/// A generic EPP Response to an EPP command with a result section, a status code and a message -pub type EppCommandResponse = ResponseStatus; - /// Type corresponding to the tag an EPP response XML #[derive(Serialize, Deserialize, Debug, PartialEq)] pub struct Undef;