3.x: Authentication adapter "FOC/Authenticate.Cookie" was not found.
hrasoa opened this issue · 5 comments
Got: Authentication adapter "FOC/Authenticate.Cookie" was not found
when loading my app.
In my config/bootstrap.php:
Plugin::load('FOC/Authenticate');
Did you try running composer update
?
Yes, already tried to delete the plugin and did composer update
too but didn't work.
In my composer.json, I added
"autoload": {
"psr-4": {
"FOC\\Authenticate\\": "./plugins/FOC/Authenticate/src"
}
}
Now i got: CookieComponent is not loaded
Well mapping the plugin's path that way shouldn't be required. Did running composer require friendsofcake/authenticate:dev-cake3
complete successfully without errors?
Now i got: CookieComponent is not loaded
So load the component in your controller. The authenticate class won't do it for you.
Hi Admad.
I've same problem.
I did "composer require friendsofcake/authenticate".
After did this, i got Authenticate inside plugins folder: http://prntscr.com/4s9kzl
Then load it in bootstrap "Plugin::load('FOC/Authenticate');" : http://prntscr.com/4s9lax
Then i configure in AppController like this: http://prntscr.com/4s9klq
Finally when i access to site, i get an error: http://prntscr.com/4s9lem
Please guide me how to fix it.
Thanks
@anhtuank7c The plugin should be installed under plugins/FOC/Authenticate
not plugins/Authenticate
. I have made updates to the plugin's composer.json and checked using fresh skeleton app. The plugin is installed in proper location and the authenticate classes can be used as documented without errors.