mirror of
https://github.com/chatmail/core.git
synced 2026-05-13 11:56:30 +03:00
Fix one clippy::unneeded_unwrap warning
This commit is contained in:
10
src/imap.rs
10
src/imap.rs
@@ -479,14 +479,12 @@ impl Imap {
|
|||||||
0, "IMAP unsetup_handle step 1 (closing down stream)."
|
0, "IMAP unsetup_handle step 1 (closing down stream)."
|
||||||
);
|
);
|
||||||
let stream = self.stream.write().unwrap().take();
|
let stream = self.stream.write().unwrap().take();
|
||||||
if stream.is_some() {
|
if let Some(stream) = stream {
|
||||||
match stream.unwrap().shutdown(net::Shutdown::Both) {
|
if let Err(err) = stream.shutdown(net::Shutdown::Both) {
|
||||||
Ok(_) => {}
|
eprintln!("failed to shutdown connection: {:?}", err);
|
||||||
Err(err) => {
|
|
||||||
eprintln!("failed to shutdown connection: {:?}", err);
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
info!(
|
info!(
|
||||||
context,
|
context,
|
||||||
0, "IMAP unsetup_handle step 2 (acquiring session.lock)"
|
0, "IMAP unsetup_handle step 2 (acquiring session.lock)"
|
||||||
|
|||||||
Reference in New Issue
Block a user