diff --git a/runtime/src/command.rs b/runtime/src/command.rs index cd4c51ff05..b74097bdfc 100644 --- a/runtime/src/command.rs +++ b/runtime/src/command.rs @@ -40,9 +40,9 @@ impl Command { /// Creates a [`Command`] that performs the action of the given future. pub fn perform( - future: impl Future + 'static + MaybeSend, - f: impl FnOnce(T) -> A + 'static + MaybeSend, - ) -> Command { + future: impl Future + 'static + MaybeSend, + f: impl FnOnce(A) -> T + 'static + MaybeSend, + ) -> Command { use iced_futures::futures::FutureExt; Command::single(Action::Future(Box::pin(future.map(f))))