laravel / sanctum

Laravel Sanctum provides a featherweight authentication system for SPAs and simple APIs.
https://laravel.com/docs/sanctum
MIT License
2.75k stars 296 forks source link

Extract generate token method #488

Closed mowangjuanzi closed 10 months ago

mowangjuanzi commented 10 months ago

I need to rewrite the createToken method, but the way the token is generated does not need to be modified by me. By extracting the method, I can avoid the impact of my rewrite on the original function.