diff --git a/packages/hooks/src/use_coroutine.rs b/packages/hooks/src/use_coroutine.rs index 347ec38fd..3a7016164 100644 --- a/packages/hooks/src/use_coroutine.rs +++ b/packages/hooks/src/use_coroutine.rs @@ -110,7 +110,6 @@ pub fn use_coroutine_handle() -> Coroutine { use_hook(consume_context::>) } -#[derive(PartialEq)] pub struct Coroutine { needs_regen: Signal, tx: CopyValue>>, @@ -149,3 +148,9 @@ impl Clone for Coroutine { *self } } + +impl PartialEq for Coroutine { + fn clone(&self) -> Self { + self.needs_regen == other.needs_regen && self.tx == other.tx && self.task == other.task + } +}