mirror of
https://github.com/house-of-vanity/desubot.git
synced 2025-08-21 15:27:14 +00:00
Trying to fix clippy. doesn't work.
This commit is contained in:
@@ -367,18 +367,20 @@ impl Execute for Omedeto {
|
|||||||
.map(|m| m.split(' ').map(|s| s.to_string()).collect::<Vec<String>>()[1].clone())
|
.map(|m| m.split(' ').map(|s| s.to_string()).collect::<Vec<String>>()[1].clone())
|
||||||
.filter(|m| {
|
.filter(|m| {
|
||||||
let stem = mystem.stemming(m.clone()).unwrap_or_default();
|
let stem = mystem.stemming(m.clone()).unwrap_or_default();
|
||||||
if stem.is_empty() {
|
if !stem.is_empty() {
|
||||||
false
|
if !stem[0].lex.is_empty() {
|
||||||
} else if stem[0].lex.is_empty() {
|
match stem[0].lex[0].grammem.part_of_speech {
|
||||||
false
|
mystem::PartOfSpeech::Noun => stem[0].lex[0]
|
||||||
} else {
|
.grammem
|
||||||
match stem[0].lex[0].grammem.part_of_speech {
|
.facts
|
||||||
mystem::PartOfSpeech::Noun => stem[0].lex[0]
|
.contains(&mystem::Fact::Case(Nominative)),
|
||||||
.grammem
|
_ => false,
|
||||||
.facts
|
}
|
||||||
.contains(&mystem::Fact::Case(Nominative)),
|
} else {
|
||||||
_ => false,
|
false
|
||||||
}
|
}
|
||||||
|
} else {
|
||||||
|
false
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
.map(|w| w.replace(|z| z == '.' || z == ',', ""))
|
.map(|w| w.replace(|z| z == '.' || z == ',', ""))
|
||||||
|
Reference in New Issue
Block a user