fields: don't crash storing items field if there's no options (#40536)
This commit is contained in:
parent
789cf1a53d
commit
e3c5b3be9b
|
@ -1704,8 +1704,9 @@ class ItemsField(WidgetField):
|
|||
return values
|
||||
|
||||
def store_display_value(self, data, field_id):
|
||||
kwargs = {}
|
||||
options = self.get_options()
|
||||
if not options:
|
||||
return ''
|
||||
choices = []
|
||||
for choice in data.get(field_id) or []:
|
||||
if type(options[0]) is str:
|
||||
|
|
Loading…
Reference in New Issue