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


##########
guacamole/src/main/java/org/apache/guacamole/rest/user/UserResource.java:
##########
@@ -150,6 +150,10 @@ public void updateObject(APIUser modifiedObject) throws 
GuacamoleException {
             throw e;
         }
 
+        /* Force updateObject to save the timezone when it is empty */
+        if (modifiedObject.getAttributes().get("timezone") == null)
+            modifiedObject.getAttributes().put("timezone", "");
+

Review Comment:
   Hmmm...it's possible that this is a bug, then, in the setting process, that 
needs to be corrected - IIRC, attributes that are null should be removed 
completely if they exist, not ignored. So, I suspect some amount of fixing is 
indeed needed, here; however, I'm not sure that changing from `null` to an 
empty string is the best way to accomplish this - without looking at things in 
detail, it seems like this just ignores the underlying problem and works around 
it rather than actually fixing it.
   
   I very well could be mistaken, though...



-- 
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: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to