fix: don't unwrap Option<Task>

This commit is contained in:
Jonathan Kelley committed 2025-10-04 10:57:46 -07:00
1 parent c29cef4ea3
commit 9bf4d97838
1 file changed
+1 -1
+1 -1
View File
@@ -194,7 +194,7 @@ pub fn spawn_forever(fut: impl Future<Output = ()> + 'static) -> Task {
///
/// This drops the task immediately.
pub fn remove_future(id: Task) {
Runtime::with(|rt| rt.remove_task(id)).expect("Runtime to exist");
Runtime::with(|rt| rt.remove_task(id));
}
/// Store a value between renders. The foundational hook for all other hooks.