matrei commented on code in PR #16209:
URL: https://github.com/apache/grails-core/pull/16209#discussion_r3842410669


##########
grails-web-databinding/src/main/groovy/grails/web/databinding/GrailsWebDataBinder.groovy:
##########
@@ -545,7 +545,17 @@ class GrailsWebDataBinder extends SimpleDataBinder {
                                 }
                             }
                             if (persistentInstance == null) {
-                                if (item instanceof Map || item instanceof 
DataBindingSource) {
+                                if (item == null || 
referencedType.isAssignableFrom(item.getClass())) {

Review Comment:
   IntelliJ complains: "Cannot resolve symbol 'getClass'"
   `inferred type: ?`
   
   ```suggestion
                                   if (item == null || 
referencedType.isAssignableFrom((Object) item.getClass())) {
   ```



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