From e76b829830e22dfd51b1717456aad015fe1d7afe Mon Sep 17 00:00:00 2001 From: Denis Stepanov Date: Tue, 5 Dec 2023 11:34:08 +0100 Subject: [PATCH] Correct nullable router signature (#10201) --- router/src/main/java/io/micronaut/web/router/Router.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/router/src/main/java/io/micronaut/web/router/Router.java b/router/src/main/java/io/micronaut/web/router/Router.java index 1dfbe74d81..0b2a23d851 100644 --- a/router/src/main/java/io/micronaut/web/router/Router.java +++ b/router/src/main/java/io/micronaut/web/router/Router.java @@ -150,7 +150,7 @@ default Stream> find(@NonNull HttpRequest request * @return A match or null, throws {@link DuplicateRouteException} on multiple routes. * @since 4.0.0 */ - @NonNull + @Nullable default UriRouteMatch findClosest(@NonNull HttpRequest request) throws DuplicateRouteException { List> uriRoutes = findAllClosest(request); if (uriRoutes.size() > 1) {