Skip to content

Commit

Permalink
Restore getUseRelativeRedirects in deprecated form
Browse files Browse the repository at this point in the history
Restore the `getUseRelativeRedirects` method with a `Boolean` object
result and introduce `isUseRelativeRedirects` for the primitive boolean
variant.

See gh-20796
  • Loading branch information
philwebb committed May 13, 2020
1 parent 5157a75 commit daed512
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 2 deletions.
Expand Up @@ -537,7 +537,12 @@ public void setRedirectContextRoot(Boolean redirectContextRoot) {
this.redirectContextRoot = redirectContextRoot;
}

public boolean getUseRelativeRedirects() {
@Deprecated
public Boolean getUseRelativeRedirects() {
return this.useRelativeRedirects;
}

public boolean isUseRelativeRedirects() {
return this.useRelativeRedirects;
}

Expand Down
Expand Up @@ -54,7 +54,7 @@ public void customize(TomcatServletWebServerFactory factory) {
if (tomcatProperties.getRedirectContextRoot() != null) {
customizeRedirectContextRoot(factory, tomcatProperties.getRedirectContextRoot());
}
customizeUseRelativeRedirects(factory, tomcatProperties.getUseRelativeRedirects());
customizeUseRelativeRedirects(factory, tomcatProperties.isUseRelativeRedirects());
factory.setDisableMBeanRegistry(!tomcatProperties.getMbeanregistry().isEnabled());
}

Expand Down

0 comments on commit daed512

Please sign in to comment.