mirror of
https://forgejo.ellis.link/continuwuation/continuwuity.git
synced 2025-07-05 19:55:49 +02:00
Fix clippy::unnecessary-unwrap.
Signed-off-by: Jason Volk <jason@zemos.net>
This commit is contained in:
parent
3c7c641d2d
commit
143cb55ac8
1 changed files with 4 additions and 2 deletions
|
@ -242,12 +242,14 @@ async fn db_lt_12(services: &Services) -> Result<()> {
|
||||||
[".m.rules.contains_user_name", ".m.rule.contains_user_name"];
|
[".m.rules.contains_user_name", ".m.rule.contains_user_name"];
|
||||||
|
|
||||||
let rule = rules_list.content.get(content_rule_transformation[0]);
|
let rule = rules_list.content.get(content_rule_transformation[0]);
|
||||||
if rule.is_some() {
|
|
||||||
let mut rule = rule.unwrap().clone();
|
if let Some(rule) = rule {
|
||||||
|
let mut rule = rule.clone();
|
||||||
content_rule_transformation[1].clone_into(&mut rule.rule_id);
|
content_rule_transformation[1].clone_into(&mut rule.rule_id);
|
||||||
rules_list
|
rules_list
|
||||||
.content
|
.content
|
||||||
.shift_remove(content_rule_transformation[0]);
|
.shift_remove(content_rule_transformation[0]);
|
||||||
|
|
||||||
rules_list.content.insert(rule);
|
rules_list.content.insert(rule);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Reference in a new issue