[java] Deleting redundant checks
@@ -45,7 +45,7 @@ public GridNodeCliOptions parse(String[] args) {
}
private IDefaultProvider defaults(String json) {
- Map<String, Object> map = (Map<String, Object>) new Json().toType(json, Map.class);
+ Map<String, Object> map = new Json().toType(json, Map.class);
map.remove("custom");
map.remove("capabilities");
map.remove("servlets");
@@ -219,13 +219,9 @@ public GridNodeConfiguration toConfiguration() {
configuration.hubPort = null;
} else if (hubHost != null && hubPort != null) {
configuration.hub = null;
- if (hubHost != null) {
configuration.hubHost = hubHost;
- }
- if (hubPort != null) {
configuration.hubPort = hubPort;
}
- }
if (configFile != null) {
configuration.nodeConfigFile = configFile;
}
