Skip to content

Commit

Permalink
update null annotations
Browse files Browse the repository at this point in the history
  • Loading branch information
stefanseifert committed Jul 17, 2024
1 parent c22c82f commit 1bc56be
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -125,7 +125,7 @@ public String relativeLink(SlingHttpServletRequest request, String path) {
return getMappedPath(request.getResourceResolver(), path);
}

private String buildExternalLink(@Nullable ResourceResolver resourceResolver, String domain, String scheme, String path) {
private String buildExternalLink(@Nullable ResourceResolver resourceResolver, @NotNull String domain, @Nullable String scheme, @NotNull String path) {
URI domainURI = domainMappings.get(Objects.requireNonNull(domain));
if (domainURI == null) {
throw new IllegalArgumentException("No mapping defined for: " + domain);
Expand All @@ -149,7 +149,7 @@ private String buildExternalLink(@Nullable ResourceResolver resourceResolver, St
return url.toString();
}

private String buildAbsoluteLink(@NotNull SlingHttpServletRequest request, String scheme, String path) {
private String buildAbsoluteLink(@NotNull SlingHttpServletRequest request, @NotNull String scheme, @NotNull String path) {

// return path unchanged if it is already absolute (or if no request available)
if (StringUtils.contains(path, SCHEME_SEPARATOR)) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
* #%L
* wcm.io
* %%
* Copyright (C) 2021 wcm.io
* Copyright (C) 2024 wcm.io
* %%
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
Expand Down

0 comments on commit 1bc56be

Please sign in to comment.