@@ -104,8 +104,7 @@ |
||
| 104 | 104 | if ($this->matrixBlockType) |
| 105 | 105 | { |
| 106 | 106 | return $this->matrixBlockType; |
| 107 | - } |
|
| 108 | - else |
|
| 107 | + } else |
|
| 109 | 108 | { |
| 110 | 109 | return Craft::$app->matrix->getBlockTypeById($this->matrixBlockTypeId); |
| 111 | 110 | } |
@@ -154,8 +154,7 @@ |
||
| 154 | 154 | if (!$spoonedBlockType = Spoon::$plugin->blockTypes->getById($spoonedBlockTypeId)) { |
| 155 | 155 | return false; |
| 156 | 156 | } |
| 157 | - } |
|
| 158 | - else |
|
| 157 | + } else |
|
| 159 | 158 | { |
| 160 | 159 | return false; |
| 161 | 160 | } |
@@ -100,8 +100,7 @@ |
||
| 100 | 100 | $section = Craft::$app->sections->getSectionByHandle($segments[1]); |
| 101 | 101 | $sectionEntryTypes = $section->getEntryTypes(); |
| 102 | 102 | $entryType = reset($sectionEntryTypes); |
| 103 | - } |
|
| 104 | - else |
|
| 103 | + } else |
|
| 105 | 104 | { |
| 106 | 105 | $entryId = explode('-',$segments[2])[0]; |
| 107 | 106 | $entry = Craft::$app->entries->getEntryById($entryId); |
@@ -120,8 +120,7 @@ discard block |
||
| 120 | 120 | |
| 121 | 121 | $blockTypeRecords = BlockTypeRecord::find()->where($condition)->all(); |
| 122 | 122 | |
| 123 | - } |
|
| 124 | - else |
|
| 123 | + } else |
|
| 125 | 124 | { |
| 126 | 125 | $condition = [ |
| 127 | 126 | 'context' => $context |
@@ -145,8 +144,7 @@ discard block |
||
| 145 | 144 | $this->_blockTypesByContext[$context][$blockType->id] = $blockType; |
| 146 | 145 | } |
| 147 | 146 | |
| 148 | - } |
|
| 149 | - else |
|
| 147 | + } else |
|
| 150 | 148 | { |
| 151 | 149 | return []; |
| 152 | 150 | } |
@@ -160,8 +158,7 @@ discard block |
||
| 160 | 158 | $return[$blockType->$groupBy][] = $blockType; |
| 161 | 159 | } |
| 162 | 160 | return $return; |
| 163 | - } |
|
| 164 | - else |
|
| 161 | + } else |
|
| 165 | 162 | { |
| 166 | 163 | return $this->_blockTypesByContext[$context]; |
| 167 | 164 | } |
@@ -188,8 +185,7 @@ discard block |
||
| 188 | 185 | { |
| 189 | 186 | throw new Exception(Craft::t('No Spoon Block Type exists with the ID “{id}”', ['id' => $blockType->id])); |
| 190 | 187 | } |
| 191 | - } |
|
| 192 | - else |
|
| 188 | + } else |
|
| 193 | 189 | { |
| 194 | 190 | $blockTypeRecord = new BlockTypeRecord(); |
| 195 | 191 | } |
@@ -327,8 +323,7 @@ discard block |
||
| 327 | 323 | // spooned blocktype model |
| 328 | 324 | $spoonedBlockType->fieldLayoutId = $layout->id; |
| 329 | 325 | |
| 330 | - } |
|
| 331 | - else |
|
| 326 | + } else |
|
| 332 | 327 | { |
| 333 | 328 | $spoonedBlockType->fieldLayoutId = null; |
| 334 | 329 | } |