Skip to content

Commit

Permalink
Code review suggestions
Browse files Browse the repository at this point in the history
  • Loading branch information
labkey-jeckels committed Jan 24, 2024
1 parent b92b2c5 commit d83536a
Showing 1 changed file with 1 addition and 7 deletions.
8 changes: 1 addition & 7 deletions api/src/org/labkey/api/view/RedirectorServlet.java
Original file line number Diff line number Diff line change
@@ -1,8 +1,3 @@
//
// Source code recreated from a .class file by IntelliJ IDEA
// (powered by FernFlower decompiler)
//

package org.labkey.api.view;

import java.io.IOException;
Expand All @@ -21,15 +16,14 @@ public RedirectorServlet(String legacyContextPath)
{
if (!legacyContextPath.startsWith("/") || legacyContextPath.length() < 2)
{
throw new IllegalArgumentException("Invalid legacy context path: " + legacyContextPath);
throw new IllegalArgumentException("Legacy context path must start with / and cannot be the root context path. Invalid path: " + legacyContextPath + ", specified via context.legacyContextPath in application.properties");
}
_legacyContextPath = legacyContextPath;
}

@Override
protected void service(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException
{

if ("get".equalsIgnoreCase(request.getMethod()))
{
// Send a redirect to let the client know there's a new preferred URL
Expand Down

0 comments on commit d83536a

Please sign in to comment.