瀏覽代碼

Fix future value never updating

Evan Almloff 1 年之前
父節點
當前提交
8af0f0a76a
共有 1 個文件被更改,包括 3 次插入0 次删除
  1. 3 0
      packages/hooks/src/usefuture.rs

+ 3 - 0
packages/hooks/src/usefuture.rs

@@ -57,6 +57,9 @@ where
         state.needs_regen.set(false);
     }
 
+    // update the current value
+    state.state.current_val = val.current_val.clone();
+
     state
 }