From 0b9942da84bb9bfc9fc1eaf4170ad71864b7c179 Mon Sep 17 00:00:00 2001 From: Yiyu Lin Date: Sat, 16 May 2020 21:41:32 +0800 Subject: fix some unwrap() in Rust (#5485) --- cli/ops/tls.rs | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) (limited to 'cli/ops') diff --git a/cli/ops/tls.rs b/cli/ops/tls.rs index 48c89be81..5cbdff300 100644 --- a/cli/ops/tls.rs +++ b/cli/ops/tls.rs @@ -291,9 +291,7 @@ impl TlsListenerResource { /// Stop tracking a task. /// Happens when the task is done and thus no further tracking is needed. pub fn untrack_task(&mut self) { - if self.waker.is_some() { - self.waker.take(); - } + self.waker.take(); } } -- cgit v1.2.3