pjfanning commented on code in PR #1142:
URL: https://github.com/apache/pekko-http/pull/1142#discussion_r3551087925
##########
http-core/src/main/scala/org/apache/pekko/http/impl/util/StreamUtils.scala:
##########
@@ -64,13 +64,10 @@ private[http] object StreamUtils {
override def onPull(): Unit = pull(in)
override def onUpstreamFinish(): Unit = {
- try {
- val data = finish()
- if (data.nonEmpty) emit(out, data)
- completeStage()
- } finally {
- finished = true
- }
+ val data = finish()
+ finished = true
+ if (data.nonEmpty) emit(out, data)
Review Comment:
@He-Pin I don't think we should refactor emit to take an extra function
param. I think that would be too large a change.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]