Laravel Passport Trying to get property ‘secret’ of non-object

THIS IS FOR LARAVEL 8 AND LARAVEL/PASSPORT

The first thing is to run the php artisan passport:install.

Inside your database table oauth_clients, under column name, look for Laravel Personal Access Client.

Copy the secret beside Laravel Personal Access Client.

Open AuthServiceProvider, then paste the secret inside the boot method where the CLIENT_SECRET is below:

Passport::personalAccessClientSecret(config('CLIENT_SECRET'));

And don’t forget to also add the ID of the secret from your database.

Passport::personalAccessClientId(config('ID'));

Use the quote along with the ID and CLIENT_SECRET as config() is expected to get a string.

Now is solved this error

dharmendra K
Tagged : / /
0 0 votes
Article Rating
Subscribe
Notify of
guest

0 Comments
Inline Feedbacks
View all comments
0
Would love your thoughts, please comment.x
()
x