summary refs log tree commit diff stats
path: root/src/components/async_fetch.rs
diff options
context:
space:
mode:
Diffstat (limited to 'src/components/async_fetch.rs')
-rw-r--r--src/components/async_fetch.rs12
1 files changed, 7 insertions, 5 deletions
diff --git a/src/components/async_fetch.rs b/src/components/async_fetch.rs
index 7bf44a0..43469a7 100644
--- a/src/components/async_fetch.rs
+++ b/src/components/async_fetch.rs
@@ -37,11 +37,13 @@ macro_rules! AsyncFetch {
             <Transition fallback=|| {
                 view! { <p>"Loading..."</p> }
             }>
-                {move || Suspend::new(async move {
-                    $resource
-                        .await
-                        .map($producer)
-                })}
+                {
+                    Suspend::new(async move {
+                        $resource
+                            .await
+                            .map($producer)
+                    })
+                }
             </Transition>
         }
     }};