@@ -14,18 +14,15 @@ |
||
| 14 | 14 | $build = []; |
| 15 | 15 | if ($this->currentUser()->isAnonymous()) { |
| 16 | 16 | $build['form'] = $this->formBuilder()->getForm(UserLoginForm::class); |
| 17 | - } |
|
| 18 | - else { |
|
| 17 | + } else { |
|
| 19 | 18 | if (\Drupal::moduleHandler()->moduleExists('moderation_dashboard') |
| 20 | 19 | && $this->currentUser()->hasPermission('use moderation dashboard')) { |
| 21 | 20 | // Permitted users are directed to their moderation dashboard. |
| 22 | 21 | return $this->redirect('view.moderation_dashboard.page_1', ['user' => $this->currentUser()->id()]); |
| 23 | - } |
|
| 24 | - elseif ($this->currentUser()->hasPermission('access content overview')) { |
|
| 22 | + } elseif ($this->currentUser()->hasPermission('access content overview')) { |
|
| 25 | 23 | // Permitted users are directed to the admin content page. |
| 26 | 24 | return $this->redirect('view.content.page_1'); |
| 27 | - } |
|
| 28 | - else { |
|
| 25 | + } else { |
|
| 29 | 26 | $build['heading'] = [ |
| 30 | 27 | '#type' => 'markup', |
| 31 | 28 | '#markup' => $this->t('This site has no homepage content.'), |