Method [logoutOtherDevices] does not exist. code example
Example: Method [logoutOtherDevices] does not exist laravel
Hi, I might be wrong. But if I remember rightly JSON web tokens are stateless
and by default arent stored in the database. The default Laravel behaviour
for this in the 'web' sessions is done by changing a cookie.
You could add this functionality yourself temporarily by storing the tokens in
the database. You could then write a middleware to check if the token exists
in the database on each request. If a user was to logoutOtherDevices you could
delete all their tokens from the database. So the middleware would deny access
on the users next requests. Hopefully this makes sense and helps a bit?