xi / django-mfa3

multi factor authentication for django
MIT License
20 stars 9 forks source link

Support applications that use a custom username field #6

Closed ashokdelphia closed 3 years ago

ashokdelphia commented 3 years ago

Use Django's indirection for getting the username.

This respects applications that have set User.USERNAME_FIELD to something else.


I'm experimenting with this lib in an app that uses a different field for the username, and I think this should make that work. I haven't tested this in detail locally yet, as I'm still sorting out some of the plumbing, but I'm reasonably confident this will behave as expected.

xi commented 3 years ago

Looks good. Thanks for the patch!

xi commented 3 years ago

Published as 0.2.5