Skip to content

Commit

Permalink
[RESTEASY-2627] Chain thenCompose properly
Browse files Browse the repository at this point in the history
  • Loading branch information
asoldano committed Sep 18, 2020
1 parent f347320 commit c2f2521
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ protected CompletionStage<Void> flushHeaders() {
} else {
value = obj.toString();
}
ret = stream.asyncWrite(key.getBytes(StandardCharsets.US_ASCII))
ret = ret.thenCompose(v -> stream.asyncWrite(key.getBytes(StandardCharsets.US_ASCII)))
.thenCompose(v -> stream.asyncWrite(AbstractMultipartWriter.COLON_SPACE_BYTES))
.thenCompose(v -> stream.asyncWrite(value.getBytes(StandardCharsets.US_ASCII)))
.thenCompose(v -> stream.asyncWrite(AbstractMultipartWriter.LINE_SEPARATOR_BYTES));
Expand Down

0 comments on commit c2f2521

Please sign in to comment.