Skip to content
Snippets Groups Projects
Commit 8eca98de authored by Jeff Burke's avatar Jeff Burke
Browse files

s1738: add get and update support to gmslcient, bug fix in GroupsActionFactory...

s1738: add get and update support to gmslcient, bug fix in GroupsActionFactory to not allow a -1 port in an url, added unit and int test
parent da3dd5a9
No related branches found
No related tags found
No related merge requests found
...@@ -137,15 +137,22 @@ public class GroupsActionFactory ...@@ -137,15 +137,22 @@ public class GroupsActionFactory
} }
else if (method.equals("POST")) else if (method.equals("POST"))
{ {
final URL requestURL = final URL requestURL = new URL(request.getRequestURL().toString());
new URL(request.getRequestURL().toString()); final StringBuilder sb = new StringBuilder();
final String redirectURI = requestURL.getProtocol() + "://" sb.append(requestURL.getProtocol());
+ requestURL.getHost() + ":" sb.append("://");
+ requestURL.getPort() sb.append(requestURL.getHost());
+ request.getContextPath() if (requestURL.getPort() > 0)
+ request.getServletPath() {
+ "/" + path; sb.append(":");
action = new ModifyGroupAction(logInfo, groupName, redirectURI, sb.append(requestURL.getPort());
}
sb.append(request.getContextPath());
sb.append(request.getServletPath());
sb.append("/");
sb.append(path);
action = new ModifyGroupAction(logInfo, groupName, sb.toString(),
request.getInputStream()); request.getInputStream());
} }
} }
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment