Skip to content

Commit

Permalink
The package-private class SingleAuthorityResolver can be final
Browse files Browse the repository at this point in the history
- Fail-fast in SingleAuthorityResolver construction for null
URIAuthority input instead of NPE in apply()
- Note: A null router has no negative side-effects in
SingleAuthorityResolver itself
  • Loading branch information
garydgregory committed Oct 29, 2024
1 parent 230ab3c commit ebb75bd
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -81,13 +81,13 @@ public String toString() {

}

static class SingleAuthorityResolver<T> implements Function<URIAuthority, T> {
static final class SingleAuthorityResolver<T> implements Function<URIAuthority, T> {

private final URIAuthority singleAuthority;
private final T router;

SingleAuthorityResolver(final URIAuthority singleAuthority, final T router) {
this.singleAuthority = singleAuthority;
this.singleAuthority = Args.notNull(singleAuthority, "singleAuthority");
this.router = router;
}

Expand Down

0 comments on commit ebb75bd

Please sign in to comment.