Ticket #12314 (closed Bug: fixed)
plone.app.users: Member data fields cannot be set to empty string
|Reported by:||reinhardt||Owned by:|
|Keywords:||zope.app.form, plone.app.users, zope.schema, member data||Cc:|
On /@@personal-information, when I set a field (say home_page) to the empty string, it does not get saved and the old value remains.
The TextWidget from zope.app.form checks if its value is missing. If yes, it sets it to self.context.missing_value. self.context is a TextLine field from zope.schema, which inherits the default missing_value from Field, which is None.
Thus, when plone.app.users tries to set the property home_page, it finds a None value and skips updating.
I suggest that TextWidget should have the empty string as missing_value, but I'm not too familiar with this code and could be wrong.
- Priority changed from minor to trivial
- Component changed from Unknown to Infrastructure
- Milestone set to 4.x
- Summary changed from Member data fields cannot be set to empty string to plone.app.users: Member data fields cannot be set to empty string