CLOUDSTACK-8817: listFirewallRules response JSON startport/endport not an int

This commit is contained in:
Ashwin Swaroop 2015-09-13 14:45:44 -04:00
parent 4d626c11bc
commit 221624d2fe
2 changed files with 4 additions and 4 deletions

View File

@ -87,11 +87,11 @@ public class FirewallResponse extends BaseResponse {
this.protocol = protocol;
}
public void setStartPort(String startPort) {
public void setStartPort(Integer startPort) {
this.startPort = startPort;
}
public void setEndPort(String endPort) {
public void setEndPort(Integer endPort) {
this.endPort = endPort;
}

View File

@ -2124,11 +2124,11 @@ public class ApiResponseHelper implements ResponseGenerator {
response.setId(fwRule.getUuid());
response.setProtocol(fwRule.getProtocol());
if (fwRule.getSourcePortStart() != null) {
response.setStartPort(Integer.toString(fwRule.getSourcePortStart()));
response.setStartPort(fwRule.getSourcePortStart());
}
if (fwRule.getSourcePortEnd() != null) {
response.setEndPort(Integer.toString(fwRule.getSourcePortEnd()));
response.setEndPort(fwRule.getSourcePortEnd());
}
List<String> cidrs = ApiDBUtils.findFirewallSourceCidrs(fwRule.getId());