mirror of
https://github.com/leptos-rs/leptos
synced 2024-11-10 14:54:16 +00:00
fix: dispose of watch
effect normally
This commit is contained in:
parent
41a18a1218
commit
40ecc2bd78
1 changed files with 1 additions and 5 deletions
|
@ -1175,11 +1175,7 @@ impl RuntimeId {
|
||||||
);
|
);
|
||||||
|
|
||||||
(id, move || {
|
(id, move || {
|
||||||
with_runtime(|runtime| {
|
with_runtime(|runtime| runtime.dispose_node(id)).expect(
|
||||||
runtime.nodes.borrow_mut().remove(id);
|
|
||||||
runtime.node_sources.borrow_mut().remove(id);
|
|
||||||
})
|
|
||||||
.expect(
|
|
||||||
"tried to stop a watch in a runtime that has been disposed",
|
"tried to stop a watch in a runtime that has been disposed",
|
||||||
);
|
);
|
||||||
})
|
})
|
||||||
|
|
Loading…
Reference in a new issue