Fix KeywordSection::load not deserializing correctly

This commit is contained in:
0xf8 2023-04-20 18:09:13 -04:00
parent 033f41b0ac
commit 91b587f7db
Signed by: 0xf8
GPG Key ID: 446580D758689584

View File

@ -5,7 +5,7 @@ use serde::{Deserialize, Serialize};
#[derive(Debug, Clone, Deserialize, Serialize)] #[derive(Debug, Clone, Deserialize, Serialize)]
pub struct KeywordSection { pub struct KeywordSection {
pub threshold: u64, pub threshold: u64,
pub required: Vec<String>, pub requiredKeywords: Vec<String>,
pub keywords: Vec<String>, pub keywords: Vec<String>,
} }
@ -27,7 +27,7 @@ impl KeywordSection {
} }
} }
for rkw in self.required.to_owned() { for rkw in self.requiredKeywords.to_owned() {
if s.contains(&rkw) { if s.contains(&rkw) {
hits += 1; hits += 1;
hit_required = true; hit_required = true;