follow-up from #1178052: Unsetting entity relationships does not work:
* we should fix validate() to not allow NULL values / empty lists in case a property is required.
* setting a multiple field to NULL results in warnings

CommentFileSizeAuthor
#2 entity_unset_fix.patch6.73 KBfago
#1 entity_unset_fix.patch2.09 KBfago
Support from Acquia helps fund testing for Drupal Acquia logo

Comments

fago’s picture

Status: Active » Needs review
Issue tags: +Needs tests
FileSize
2.09 KB

attached patch works for me, we should add some tests though.

fago’s picture

Status: Needs review » Fixed
FileSize
6.73 KB

I've added tests + some further improvements, see attached patch.

As tests are green, I've committed the patch.

Automatically closed -- issue fixed for 2 weeks with no activity.