From 28855626959d2b78227dfb539af2212894d1b3ae Mon Sep 17 00:00:00 2001 From: vkorchik Date: Sat, 17 Feb 2024 17:03:35 +0100 Subject: [PATCH] interruptFork --- .../shared/src/main/scala/zio/interop/cats.scala | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/zio-interop-cats/shared/src/main/scala/zio/interop/cats.scala b/zio-interop-cats/shared/src/main/scala/zio/interop/cats.scala index d6e77f06..ce5edb67 100644 --- a/zio-interop-cats/shared/src/main/scala/zio/interop/cats.scala +++ b/zio-interop-cats/shared/src/main/scala/zio/interop/cats.scala @@ -448,9 +448,10 @@ private abstract class ZioConcurrent[R, E, E1] leftFiber.id <> rightFiber.id ) .onInterrupt( - leftFiber.interruptAsFork(parentFiber.id) *> rightFiber.interruptAsFork( - parentFiber.id - ) *> leftFiber.await *> rightFiber.await + leftFiber.interruptFork *> + rightFiber.interruptFork *> + leftFiber.await *> + rightFiber.await ) } }