public function init()
    {
        Yii::setAlias('@maintenance', $this->commandPath);
        if (!file_exists(Yii::getAlias('@maintenance'))) {
            FileHelper::createDirectory(Yii::getAlias('@maintenance'));
        }
        if (Yii::$app instanceof \yii\console\Application) {
            Yii::$app->controllerMap['maintenance'] = $this->consoleController;
        } else {
            if ($this->getIsEnabled()) {
                $this->filtering();
            }
        }
    }