示例#1
0
 /**
  * @inheritdoc
  * @throws Exception
  * @throws \yii\base\InvalidConfigException
  */
 public function init()
 {
     $this->storagePath = \Yii::getAlias($this->storagePath);
     if (!is_dir($this->storagePath)) {
         if (!@FileHelper::createDirectory($this->storagePath, $this->dirMode)) {
             throw new Exception('Unable to create TLE storage directory "' . $this->storagePath . '"');
         }
     }
     parent::init();
 }
示例#2
0
 /**
  * @inheritdoc
  * @throws \yii\base\InvalidConfigException
  */
 public function init()
 {
     parent::init();
     $this->db = Instance::ensure($this->db);
 }