Skip to content

Commit

Permalink
Merge pull request django-wiki#269 from fangsterr/master
Browse files Browse the repository at this point in the history
article settings form compatibility with custom user model
  • Loading branch information
benjaoming committed Jul 11, 2014
2 parents 8a7f288 + 5521c3b commit bacba8d
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion wiki/forms.py
Original file line number Diff line number Diff line change
Expand Up @@ -372,7 +372,7 @@ def __init__(self, article, request, *args, **kwargs):
self.fields['recursive_owner'].widget = forms.HiddenInput()
self.fields['locked'].widget = forms.HiddenInput()

self.fields['owner_username'].initial = article.owner.username if article.owner else ""
self.fields['owner_username'].initial = getattr(article.owner, User.USERNAME_FIELD) if article.owner else ""

def clean_owner_username(self):
if self.can_assign:
Expand Down

0 comments on commit bacba8d

Please sign in to comment.