laravel / passport

Laravel Passport provides OAuth2 server support to Laravel.
https://laravel.com/docs/passport
MIT License
3.29k stars 780 forks source link

retrieve primary key identifier in AuthCodeRepository & TokenRepository #1786

Closed JorrinKievit closed 2 months ago

JorrinKievit commented 2 months ago

I am using custom table and column names for all Passport created tables. Everything works using the class overrides, except for these particular queries in AuthCodeRepository and TokenRepository. I use mutators to rewrite some model attributes, but that was not working for both. Now this query respects the set primary key on the authCode & token model instead. I am fairly new to Laravel, so there might be a better solution 😄.

This code also exists in 13.x, so I guess this should be merged into 13.x too?

taylorotwell commented 2 months ago

Thanks for your pull request to Laravel!

Unfortunately, I'm going to delay merging this code for now. To preserve our ability to adequately maintain the framework, we need to be very careful regarding the amount of code we include.

If applicable, please consider releasing your code as a package so that the community can still take advantage of your contributions!