Skip to content

Commit

Permalink
chore: Clean up some duplicated code.
Browse files Browse the repository at this point in the history
  • Loading branch information
He-Pin committed Jan 19, 2024
1 parent 7b2a3d8 commit db53e67
Showing 1 changed file with 4 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -193,9 +193,8 @@ import pekko.util.ccompat._
} catch {
case NonFatal(ex) =>
decider(ex) match {
case Supervision.Stop => failStage(ex)
case Supervision.Resume => if (!hasBeenPulled(in)) pull(in)
case Supervision.Restart => if (!hasBeenPulled(in)) pull(in)
case Supervision.Stop => failStage(ex)
case _ => pull(in)
}
}

Expand Down Expand Up @@ -267,9 +266,8 @@ private[stream] object Collect {
} catch {
case NonFatal(ex) =>
decider(ex) match {
case Supervision.Stop => failStage(ex)
case Supervision.Resume => if (!hasBeenPulled(in)) pull(in)
case Supervision.Restart => if (!hasBeenPulled(in)) pull(in)
case Supervision.Stop => failStage(ex)
case _ => pull(in)
}
}

Expand Down

0 comments on commit db53e67

Please sign in to comment.