You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
127.0.0.1:52605 [200]: /login - Cannot use object of type stdClass as array in /.../vendor/jeremykendall/slim-auth/src/JeremyKendall/Slim/Auth/Adapter/Db/PdoAdapter.php on line 90
I am using following code:
$adapter = new PdoAdapter(
$db,
'Students',
'email',
'password',
new PasswordValidator()
);
$acl = new \Mini\Acl();
$authBootstrap = new Bootstrap($app, $adapter, $acl);
$authBootstrap->bootstrap();
$app->add(new \Slim\Middleware\SessionCookie());
I also added the cookies config and example route. Am I doing something wrong?
The text was updated successfully, but these errors were encountered:
It seems you have \PDO::ATTR_DEFAULT_FETCH_MODE set to \PDO::FETCH_OBJ rather than \PDO::FETCH_ASSOC (or one of the other fetch modes that includes an associative array).
A quick fix for you might be to choose \PDO::FETCH_LAZY for now, but this is definitely an oversight on my part. I need to set a fetch mode in the PdoAdapter.
Hello,
I am receiving following error:
127.0.0.1:52605 [200]: /login - Cannot use object of type stdClass as array in /.../vendor/jeremykendall/slim-auth/src/JeremyKendall/Slim/Auth/Adapter/Db/PdoAdapter.php on line 90
I am using following code:
I also added the cookies config and example route. Am I doing something wrong?
The text was updated successfully, but these errors were encountered: