Skip to content

Commit

Permalink
Merge branch 'v236'
Browse files Browse the repository at this point in the history
  • Loading branch information
jpclark6 committed Jan 30, 2020
2 parents 74be7a9 + c04bdcb commit 1748ab0
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions autocomplete_light/forms.py
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,7 @@ def __init__(self, *args, **kwargs):
super(VirtualFieldHandlingMixin, self).__init__(*args, **kwargs)

# do what model_to_dict doesn't
for field in self._meta.model._meta.virtual_fields:
for field in self._meta.model._meta.private_fields:
try:
self.initial[field.name] = getattr(self.instance, field.name,
None)
Expand All @@ -102,7 +102,7 @@ def _post_clean(self):
from django.contrib.contenttypes.models import ContentType

# take care of virtual fields since django doesn't
for field in self._meta.model._meta.virtual_fields:
for field in self._meta.model._meta.private_fields:
value = self.cleaned_data.get(field.name, None)

if value:
Expand Down

0 comments on commit 1748ab0

Please sign in to comment.