code: public function init()
      {
          parent::init();
  
          if ($this->identityClass === null) {
              throw new InvalidConfigException('User::identityClass must be set.');
          }
          if ($this->enableAutoLogin && !isset($this->identityCookie['name'])) {
              throw new InvalidConfigException('User::identityCookie must contain the "name" element.');
          }
          if (!empty($this->accessChecker) && is_string($this->accessChecker)) {
              $this->accessChecker = Yii::createObject($this->accessChecker);
          }
      }
docs: Initializes the application component.