coolcsn / CsnUser

Authentication module using Doctrine
MIT License
33 stars 36 forks source link

Email as Username #4

Closed dennis-fedco closed 11 years ago

dennis-fedco commented 11 years ago

In my application I want to use user's email as their username, and remove the field "username" from all view entirely. Users then will use their email and password to log in.

Internally, to minimize the code changes, it can be done by having: username = email in the appropriate Controller.

I am considering editing the module directly, but concerned that future module updates will make my changes disappear. Is it the best practice to move this out into configuration of the module? What do you recommend I do?

coolcsn commented 11 years ago

I am afraid currently there is no such configuration parameter. I will add this requirement in the ToDo list for the release. If you manually change the code now and install the release afterwords all you have to do is just set the option. I think the easiest solution will be to go ahead and change the code for now.

coolcsn commented 11 years ago

If you want to avoid changing the code the best maybe will be to extend the controller in your own module and change the route so it uses your controller. But I don't know what problems you will face in this case.

dennis-fedco commented 11 years ago

I will just go ahead and change the code in this case. Thanks!