nfoert / cardie

An open source business card designer and sharing platform
https://cardie-uwtwy.ondigitalocean.app/
GNU General Public License v3.0
377 stars 24 forks source link

Using CustomUser named model instead of User model #81

Open spline2hg opened 6 days ago

spline2hg commented 6 days ago

I would like to propose considering the use of a custom user model and a custom user manager instead of the default user model. This approach would allow us to utilize request.user for accessing user data, eliminating the need to retrieve the username from the session. Combining both session data and a custom user model could be quite approachable , thanks

nfoert commented 6 days ago

This would definitely be a good implementation, I know that the way I've set up the User model is not necessarily the best way Would a new model need to be created or could the existing one be used?

spline2hg commented 5 days ago

we could just rename the User model that would also work ig.then we could use request.user to get the authenticated user instance.

nfoert commented 5 days ago

we could just rename the User model that would also work ig.then we could use request.user to get the authenticated user instance.

This seems like a good change, I think this would be related to #32, it seems that there's a lot of changes to the authentication system that would be beneficial, this change would likely be involved in this rework