Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Switching from username to users id #280

Open
markwingerd opened this issue Nov 1, 2018 · 1 comment
Open

Switching from username to users id #280

markwingerd opened this issue Nov 1, 2018 · 1 comment

Comments

@markwingerd
Copy link

Is there a way to use a user's id instead of their username?

In my django project I have a few views which receive a user_id but have no use for any other part of the User object. These views need to be very fast and retrieving the User object just to get the username isn't ideal. I was wondering if it's possible in the current implementation or if an improvement could be made to get this functionality.

@jrief
Copy link
Owner

jrief commented Nov 1, 2018

It probably is easy to implement. But how would you do that in a generic and portable manner? Isn't it easier for you to transfer the username to the client?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants