necouchman commented on code in PR #795:
URL: https://github.com/apache/guacamole-client/pull/795#discussion_r1554793597


##########
extensions/guacamole-auth-json/src/main/java/org/apache/guacamole/auth/json/connection/ConnectionService.java:
##########
@@ -176,6 +177,21 @@ public GuacamoleTunnel connect(UserData.Connection 
connection,
         String hostname = proxyConfig.getHostname();
         int port = proxyConfig.getPort();
 
+        // handle guacd-[hostname/port/ssl] overrides
+        String overrideGuacdHostname = connection.getGuacdHostname();
+        if (overrideGuacdHostname != null && !overrideGuacdHostname.isEmpty()) 
{
+            hostname = overrideGuacdHostname;
+        }
+        Integer overrideGuacdPort = connection.getGuacdPort();

Review Comment:
   I think we prefer `int` over `Integer` unless you need the extra 
functionality of `Integer`.



##########
extensions/guacamole-auth-json/src/main/java/org/apache/guacamole/auth/json/connection/ConnectionService.java:
##########
@@ -176,6 +177,21 @@ public GuacamoleTunnel connect(UserData.Connection 
connection,
         String hostname = proxyConfig.getHostname();
         int port = proxyConfig.getPort();
 
+        // handle guacd-[hostname/port/ssl] overrides
+        String overrideGuacdHostname = connection.getGuacdHostname();
+        if (overrideGuacdHostname != null && !overrideGuacdHostname.isEmpty()) 
{
+            hostname = overrideGuacdHostname;
+        }
+        Integer overrideGuacdPort = connection.getGuacdPort();
+        if (overrideGuacdPort != null) {
+            port = overrideGuacdPort;
+        }
+        EncryptionMethod proxyMethod = proxyConfig.getEncryptionMethod();
+        Boolean overrideGuacdSSL = connection.getGuacdSsl();

Review Comment:
   Similarly, I think we prefer `boolean` over `Boolean`, unless specifically 
requiring `Boolean`.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: dev-unsubscr...@guacamole.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org

Reply via email to