jdaugherty commented on code in PR #15699:
URL: https://github.com/apache/grails-core/pull/15699#discussion_r3341376479


##########
grails-web-databinding/src/main/groovy/org/grails/web/databinding/DefaultASTDatabindingHelper.java:
##########
@@ -145,9 +145,20 @@ private Set<String> 
getPropertyNamesToIncludeInWhiteList(final SourceUnit source
         final Set<String> propertyNamesToIncludeInWhiteList = new HashSet<>();
         final Set<String> unbindablePropertyNames = new HashSet<>();
         final Set<String> bindablePropertyNames = new HashSet<>();
+        final boolean isDomainClass = GrailsASTUtils.isDomainClass(classNode, 
sourceUnit);
         if (!classNode.getSuperClass().equals(new ClassNode(Object.class))) {
             final Set<String> parentClassPropertyNames = 
getPropertyNamesToIncludeInWhiteListForParentClass(sourceUnit, 
classNode.getSuperClass());
-            bindablePropertyNames.addAll(parentClassPropertyNames);
+            for (final String parentPropertyName : parentClassPropertyNames) {
+                // The id, version, dateCreated and lastUpdated properties of 
a domain class are never bound by default.

Review Comment:
   We should simplify the comment or just remove it.  I think the code is 
self-explanatory 



-- 
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