Merge 1.2.0 changes back to master.
diff --git a/extensions/guacamole-auth-jdbc/modules/guacamole-auth-jdbc-base/src/main/java/org/apache/guacamole/auth/jdbc/JDBCEnvironment.java b/extensions/guacamole-auth-jdbc/modules/guacamole-auth-jdbc-base/src/main/java/org/apache/guacamole/auth/jdbc/JDBCEnvironment.java
index 7c9a4b1..838ad4d 100644
--- a/extensions/guacamole-auth-jdbc/modules/guacamole-auth-jdbc-base/src/main/java/org/apache/guacamole/auth/jdbc/JDBCEnvironment.java
+++ b/extensions/guacamole-auth-jdbc/modules/guacamole-auth-jdbc-base/src/main/java/org/apache/guacamole/auth/jdbc/JDBCEnvironment.java
@@ -155,7 +155,7 @@
     /**
      * Returns a boolean value representing whether or not the JDBC module
      * should automatically create accounts within the database for users that
-     * are successfully authenticated via other extensions.  Returns true if
+     * are successfully authenticated via other extensions. Returns true if
      * accounts should be auto-created, otherwise returns false.
      * 
      * @return
diff --git a/extensions/guacamole-auth-jdbc/modules/guacamole-auth-jdbc-base/src/main/java/org/apache/guacamole/auth/jdbc/base/ModeledDirectoryObjectService.java b/extensions/guacamole-auth-jdbc/modules/guacamole-auth-jdbc-base/src/main/java/org/apache/guacamole/auth/jdbc/base/ModeledDirectoryObjectService.java
index 133e662..80bc7eb 100644
--- a/extensions/guacamole-auth-jdbc/modules/guacamole-auth-jdbc-base/src/main/java/org/apache/guacamole/auth/jdbc/base/ModeledDirectoryObjectService.java
+++ b/extensions/guacamole-auth-jdbc/modules/guacamole-auth-jdbc-base/src/main/java/org/apache/guacamole/auth/jdbc/base/ModeledDirectoryObjectService.java
@@ -411,7 +411,7 @@
 
     /**
      * Returns an immutable collection of permissions that should be granted due
-     * to the creation of the given object.  These permissions need not be
+     * to the creation of the given object. These permissions need not be
      * granted solely to the user creating the object.
      * 
      * @param user
@@ -431,15 +431,13 @@
         // thus lacking database backing.
         if (user.getUser().isSkeleton())
             return Collections.emptyList();
-
-        // Get the user model and check for an entity ID.
-        UserModel userModel = user.getUser().getModel();
         
         // Build list of implicit permissions
         Collection<ObjectPermissionModel> implicitPermissions =
                 new ArrayList<>(IMPLICIT_OBJECT_PERMISSIONS.length);
 
         
+        UserModel userModel = user.getUser().getModel();
         for (ObjectPermission.Type permission : IMPLICIT_OBJECT_PERMISSIONS) {
 
             // Create model which grants this permission to the current user