mirror of
https://github.com/c-cube/moonpool.git
synced 2025-12-10 05:03:58 -05:00
fix fut: trigger failing to attach doesn't signal it
This commit is contained in:
parent
6e05b928ed
commit
b0e4fa4563
1 changed files with 2 additions and 2 deletions
|
|
@ -67,7 +67,7 @@ let on_result (self : _ t) (f : _ waiter) : unit =
|
|||
let trigger =
|
||||
(Trigger.from_action f self on_result_cb_ [@alert "-handler"])
|
||||
in
|
||||
ignore (C.try_attach self.st trigger : bool)
|
||||
if not (C.try_attach self.st trigger) then on_result_cb_ () f self
|
||||
|
||||
let on_result_ignore_cb_ _tr f (self : _ t) =
|
||||
f (Picos.Computation.canceled self.st)
|
||||
|
|
@ -77,7 +77,7 @@ let on_result_ignore (self : _ t) f : unit =
|
|||
let trigger =
|
||||
(Trigger.from_action f self on_result_ignore_cb_ [@alert "-handler"])
|
||||
in
|
||||
ignore (C.try_attach self.st trigger : bool)
|
||||
if not (C.try_attach self.st trigger) then on_result_ignore_cb_ () f self
|
||||
) else
|
||||
on_result_ignore_cb_ () f self
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue