Conditions | 3 |
Paths | 3 |
Total Lines | 15 |
Lines | 0 |
Ratio | 0 % |
Changes | 0 |
1 | <?php |
||
42 | protected function createRules() |
||
43 | { |
||
44 | if (empty($this->moduleId)) { |
||
45 | throw new InvalidConfigException('`moduleId` must be set.'); |
||
46 | } |
||
47 | $module = Yii::$app->getModule($this->moduleId); |
||
48 | if (!$module instanceof UrlRuleCreator) { |
||
49 | throw new InvalidConfigException( |
||
50 | "Module `{$this->moduleId}` must implement " |
||
51 | . UrlRuleCreator::class |
||
52 | ); |
||
53 | } |
||
54 | |||
55 | return $module->createUrlRules($this); |
||
56 | } |
||
57 | |||
68 |