Skip to content

Commit

Permalink
Attempt to resolve watson registration error
Browse files Browse the repository at this point in the history
  • Loading branch information
tnurse18 committed Apr 10, 2021
1 parent 461085d commit c796c90
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions acct/apps.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,9 @@ class AcctConfig(AppConfig):
def ready(self):
User = django.contrib.auth.get_user_model()

if watson.is_registered(User):
watson.unregister(User)

watson.register(User, UserSearchAdapter, fields=('id', 'email',
'profile__fullname',
'profile__mdc',
Expand Down

0 comments on commit c796c90

Please sign in to comment.