diff options
author | 2024-11-24 15:09:05 +0000 | |
---|---|---|
committer | 2024-11-24 15:09:05 +0000 | |
commit | 880194d8119c222386e4461ce6bd03d43751c3a0 (patch) | |
tree | 3ad05c7882afadcdbbbdf18ea78b0958e94899f2 /src/stanza/starttls.rs | |
parent | 35f164cdb6324c6dfb635f8de93a8221861a5991 (diff) | |
download | luz-880194d8119c222386e4461ce6bd03d43751c3a0.tar.gz luz-880194d8119c222386e4461ce6bd03d43751c3a0.tar.bz2 luz-880194d8119c222386e4461ce6bd03d43751c3a0.zip |
fix: use namespace_declaration_overrides
Diffstat (limited to 'src/stanza/starttls.rs')
-rw-r--r-- | src/stanza/starttls.rs | 23 |
1 files changed, 4 insertions, 19 deletions
diff --git a/src/stanza/starttls.rs b/src/stanza/starttls.rs index 874ae66..ee35bf5 100644 --- a/src/stanza/starttls.rs +++ b/src/stanza/starttls.rs @@ -21,7 +21,7 @@ impl IntoElement for StartTls { namespace: Some(XMLNS.to_string()), local_name: "required".to_string(), }, - namespace_declarations: HashSet::new(), + namespace_declaration_overrides: HashSet::new(), attributes: HashMap::new(), content: Vec::new(), }); @@ -29,17 +29,12 @@ impl IntoElement for StartTls { } else { content = Vec::new(); } - let mut namespace_declarations = HashSet::new(); - namespace_declarations.insert(NamespaceDeclaration { - prefix: None, - namespace: XMLNS.to_string(), - }); Element { name: Name { namespace: Some(XMLNS.to_string()), local_name: "starttls".to_string(), }, - namespace_declarations, + namespace_declaration_overrides: HashSet::new(), attributes: HashMap::new(), content, } @@ -90,17 +85,12 @@ pub struct Proceed; impl IntoElement for Proceed { fn into_element(&self) -> Element { - let mut namespace_declarations = HashSet::new(); - namespace_declarations.insert(NamespaceDeclaration { - prefix: None, - namespace: XMLNS.to_string(), - }); Element { name: Name { namespace: Some(XMLNS.to_string()), local_name: "proceed".to_string(), }, - namespace_declarations, + namespace_declaration_overrides: HashSet::new(), attributes: HashMap::new(), content: Vec::new(), } @@ -128,17 +118,12 @@ pub struct Failure; impl IntoElement for Failure { fn into_element(&self) -> Element { - let mut namespace_declarations = HashSet::new(); - namespace_declarations.insert(NamespaceDeclaration { - prefix: None, - namespace: XMLNS.to_string(), - }); Element { name: Name { namespace: Some(XMLNS.to_string()), local_name: "failure".to_string(), }, - namespace_declarations, + namespace_declaration_overrides: HashSet::new(), attributes: HashMap::new(), content: Vec::new(), } |