clippy: collapse nested ifs
Signed-off-by: Fabian Grünbichler <f.gruenbichler@proxmox.com>
This commit is contained in:
1 parent
3b82f3eea5
commit
6334bdc1c5
10 files changed
+52
-74
No files matched your search
@@ -378,15 +378,13 @@ pub fn request_and_load_media(
|
||||
media_id.label.uuid.to_string(),
|
||||
));
|
||||
return Ok((Box::new(handle), media_id));
|
||||
} else {
|
||||
if Some(media_id.label.uuid.clone()) != last_media_uuid {
|
||||
worker.log(format!(
|
||||
"wrong media label {} ({})",
|
||||
media_id.label.label_text,
|
||||
media_id.label.uuid.to_string(),
|
||||
));
|
||||
last_media_uuid = Some(media_id.label.uuid);
|
||||
}
|
||||
} else if Some(media_id.label.uuid.clone()) != last_media_uuid {
|
||||
worker.log(format!(
|
||||
"wrong media label {} ({})",
|
||||
media_id.label.label_text,
|
||||
media_id.label.uuid.to_string(),
|
||||
));
|
||||
last_media_uuid = Some(media_id.label.uuid);
|
||||
}
|
||||
}
|
||||
Ok((None, _)) => {
|
||||
|
||||
Reference in new issue
Block a user