My app is work properly in 2.0.43.
After I update to 2.0.47 user identity data lost after successful login (login properly, redirect and user identity data lost, in debugger User is guest).
I suppose that metod findIdentity() of User class must work in different way in 2.0.47.
Code:
public static function findIdentity($id)
{
$connection0 = Yii::$app->db;
$command0 = $connection0->createCommand("SELECT id_osoby ..cutted.. WHERE id_osoby = :id_osoby AND other_conditions ");
$command0->bindValue(':id_osoby', $id);
$user = $command0->queryOne();
if (isset($user) && $user['id_osoby'] == $id) {
$Zgloszenia = Zgloszenia::find()
->where("id_osoby = :id_osoby", [":id_osoby" => $id])
->andwhere("status_konta > 0")
->one();
}
if (isset($Zgloszenia))
return new static($Zgloszenia);
return null;
}
Any suggestion how to change function findIdentity() ?