isAuthorized function not working after 3.4 update?

Hy!

I was litle bit stucked. I update my project to 3.4 from 3.3 and my isAtuhorized function called.
This is my componenet load:

$this->loadComponent('Auth', [
        'authorize' => ['Controller'],
        'authenticate' => [
            'Form' => [
                'fields' => [
                    'username' => 'email',
                    'password' => 'password',
                ]
            ]
        ],
        'loginRedirect' => [
            'controller' => 'Tasks',
            'action' => 'mine'
        ],
        'logoutRedirect' => [
            'controller' => 'Users',
            'action' => 'login'
        ]
    ]);

So yeah and is authorized not called, i tried in AppController and specified Controller.
Any idea what i do wrong?

Now i a fixed it. My Auth set user is missing which is intresting cuz
$this->Auth->allow()
working, whitout this
$this->Auth->setUser()

1 Like