diff --git a/src/domain/create.rs b/src/domain/create.rs index 63f18e5..13d695c 100644 --- a/src/domain/create.rs +++ b/src/domain/create.rs @@ -58,7 +58,7 @@ impl<'a> DomainCreate<'a> { domain: DomainCreateRequestData { name, period, - ns: ns.map(|ns| NameServers { ns: ns.to_vec() }), + ns: ns.map(|ns| NameServers { ns: ns.into() }), registrant, auth_info: DomainAuthInfo::new(auth_password), contacts, diff --git a/src/domain/mod.rs b/src/domain/mod.rs index 9edf87a..1a09072 100644 --- a/src/domain/mod.rs +++ b/src/domain/mod.rs @@ -130,7 +130,7 @@ pub enum HostInfo<'a> { #[derive(Debug, FromXml, ToXml)] #[xml(rename = "ns", ns(XMLNS))] pub struct NameServers<'a> { - pub ns: Vec>, + pub ns: Cow<'a, [HostInfo<'a>]>, } /// The <contact> type on domain creation and update requests