radiate-framework / framework

A WordPress plugin and theme framework
https://radiate-framework.github.io/
MIT License
4 stars 0 forks source link

Auth::attempt relies on username being set #112

Closed BenRutlandWeb closed 3 years ago

BenRutlandWeb commented 3 years ago

Describe the bug Auth:attempt() method has "username" hardcoded. This could potentially come from the User model instead.

BenRutlandWeb commented 3 years ago

The RadiateUserProvider now expects "email" instead of "username". I feel this is more consistent with most attempts at passing credentials. A potential solution to make this flexible is to add a method to the User model, however that will lead to divergence from the WordPressUserProvider as there is no way to decide what "key" to use.