Skip to content

Commit

Permalink
Resolve conflics for distributed combinators (zio#2254)
Browse files Browse the repository at this point in the history
  • Loading branch information
mschuwalow authored and iravid committed Nov 17, 2019
1 parent 048abcd commit 3c2bbbd
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions streams/shared/src/main/scala/zio/stream/ZStream.scala
Original file line number Diff line number Diff line change
Expand Up @@ -1028,8 +1028,8 @@ class ZStream[-R, +E, +A] private[stream] (private[stream] val structure: ZStrea
.foldCauseM(
{
// we ignore all downstream queues that were shut down and remove them later
case Cause.Interrupt => ZIO.succeed(id :: acc)
case c => ZIO.halt(c)
case c if c.interrupted => ZIO.succeed(id :: acc)
case c => ZIO.halt(c)
},
_ => ZIO.succeed(acc)
)
Expand Down Expand Up @@ -1066,7 +1066,7 @@ class ZStream[-R, +E, +A] private[stream] (private[stream] val structure: ZStrea
queues <- queuesRef.get.map(_.values)
_ <- ZIO.foreach(queues) { queue =>
queue.offer(endTake).catchSomeCause {
case Cause.Interrupt => ZIO.unit
case c if c.interrupted => ZIO.unit
}
}
_ <- done(endTake)
Expand Down

0 comments on commit 3c2bbbd

Please sign in to comment.