Do not clear values in lists of strings.
Some checks failed
rust-test Build rust-test has succeeded
rust-foreign-document-test Build rust-foreign-document-test has failed
rust-build Build rust-build has succeeded

This is a hold-over from when I had list of single string which was a misunderstanding of the optional pair type.
This commit is contained in:
Tom Alexander 2023-10-16 12:58:20 -04:00
parent 911634cb42
commit c86d1000c0
Signed by: talexander
GPG Key ID: D3A179C9A53C0EDE

View File

@ -48,13 +48,7 @@ where
AffiliatedKeywordValue::ListOfStrings(Vec::with_capacity(1))
});
match list_of_strings {
AffiliatedKeywordValue::ListOfStrings(list_of_strings)
if list_of_strings.is_empty() =>
{
list_of_strings.push(kw.value);
}
AffiliatedKeywordValue::ListOfStrings(list_of_strings) => {
list_of_strings.clear();
list_of_strings.push(kw.value);
}
_ => panic!("Invalid AffiliatedKeywordValue type."),