public function afterSave($insert, $changedAttributes)
    {
        parent::afterSave($insert, $changedAttributes);
        if ($this->isActive()) {
            $loginForm = new LoginForm(['username' => $this->username]);
            $loginForm->login(false);
        }
    }