Skip to content

Commit c432928

Browse files
committed
build: early set response code try to avoid OSX error
1 parent 9e1054f commit c432928

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

jooby/src/main/java/io/jooby/Route.java

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -352,7 +352,9 @@ public interface Handler extends Serializable, Aware {
352352

353353
/** Handler for {@link StatusCode#REQUEST_ENTITY_TOO_LARGE} responses. */
354354
public static final Handler REQUEST_ENTITY_TOO_LARGE =
355-
ctx -> ctx.sendError(new StatusCodeException(StatusCode.REQUEST_ENTITY_TOO_LARGE));
355+
ctx ->
356+
ctx.setResponseCode(StatusCode.REQUEST_ENTITY_TOO_LARGE)
357+
.sendError(new StatusCodeException(StatusCode.REQUEST_ENTITY_TOO_LARGE));
356358

357359
/** Handler for {@link StatusCode#NOT_ACCEPTABLE} responses. */
358360
public static final Route.Before ACCEPT =

0 commit comments

Comments
 (0)