File tree Expand file tree Collapse file tree 1 file changed +2
-4
lines changed
Expand file tree Collapse file tree 1 file changed +2
-4
lines changed Original file line number Diff line number Diff line change @@ -61,7 +61,6 @@ public void filter(final ClientRequestContext requestContext) throws IOException
6161 return ;
6262
6363 var redirectionsCount = requestContext .getProperty (REDIRECTIONS_COUNT ) instanceof Integer i ? i : 0 ;
64- final var target = requestContext .getUri ();
6564 while (PERMANENT_REDIRECTION_LOCATIONS .get (requestContext .getUri ()) instanceof URI location ) {
6665 if (redirectionsLimit instanceof Integer maxRedirects && ++redirectionsCount > maxRedirects ) {
6766 final var rc = redirectionsCount ;
@@ -71,11 +70,10 @@ public void filter(final ClientRequestContext requestContext) throws IOException
7170 requestContext .abortWith (Response .status (PERMANENT_REDIRECT ).location (location ).build ());
7271 return ;
7372 }
73+ LOGGER .finer (() -> "Following permanent redirect from '%s' to '%s'..."
74+ .formatted (requestContext .getUri (), location ));
7475 requestContext .setUri (location );
7576 }
76- if (!target .equals (requestContext .getUri ()))
77- LOGGER .finer (() -> "Following permanent redirect from '%s' to '%s'..."
78- .formatted (target , requestContext .getUri ()));
7977 requestContext .setProperty (REDIRECTIONS_COUNT , redirectionsCount );
8078 }
8179
You can’t perform that action at this time.
0 commit comments