mirror of
https://github.com/netbox-community/netbox.git
synced 2025-08-23 16:06:43 -06:00
Cleanup
This commit is contained in:
parent
2a9b58925c
commit
b36f2ba1c9
@ -49,10 +49,9 @@ class ChoiceField(serializers.Field):
|
||||
if obj != '':
|
||||
# Use an empty string in place of the choice label if it cannot be resolved (i.e. because a previously
|
||||
# configured choice has been removed from FIELD_CHOICES).
|
||||
label = self._choices.get(obj, '')
|
||||
return {
|
||||
'value': obj,
|
||||
'label': label,
|
||||
'label': self._choices.get(obj, ''),
|
||||
}
|
||||
|
||||
def to_internal_value(self, data):
|
||||
|
Loading…
Reference in New Issue
Block a user