Skip to content

Commit 6f9fb80

Browse files
committed
- Fix API object filter to only add Querystring when Queryparameters are not empty
1 parent 655d540 commit 6f9fb80

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

java/src/main/java/com/genexus/filters/APIObjectFilter.java

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,11 @@ public void doFilter(IServletRequest request, IServletResponse response, IFilte
3939
}
4040
}
4141
if(isPath) {
42-
String fwdURI = REST_SUBPART + path + QS_SEP + httpRequest.getQueryString();
42+
String fwdURI = REST_SUBPART + path;
43+
String qString = httpRequest.getQueryString();
44+
if ( qString != null && !qString.isEmpty()) {
45+
fwdURI = fwdURI + QS_SEP + qString;
46+
}
4347
logger.info("Forwarding from " + path +" to: " + fwdURI) ;
4448
httpRequest.getRequestDispatcher(fwdURI).forward(request,response);
4549
}

0 commit comments

Comments
 (0)