From f3a11213f74911e2076bec6a9164d5d2fe391c13 Mon Sep 17 00:00:00 2001 From: Thomas Gelf Date: Thu, 22 Jun 2017 02:09:31 +0200 Subject: [PATCH] cs fixes --- application/controllers/IndexController.php | 3 ++- library/Director/Dashboard/Dashboard.php | 10 +++++----- library/Director/Web/Table/ObjectsTable.php | 14 ++++++++------ library/Director/Web/Tree/TemplateTreeRenderer.php | 2 +- 4 files changed, 16 insertions(+), 13 deletions(-) diff --git a/application/controllers/IndexController.php b/application/controllers/IndexController.php index 2a2570cb..0870d028 100644 --- a/application/controllers/IndexController.php +++ b/application/controllers/IndexController.php @@ -24,7 +24,8 @@ class IndexController extends DashboardController } if ($migrations->hasPendingMigrations()) { - $this->content()->prepend($this + $this->content()->prepend( + $this ->loadForm('applyMigrations') ->setMigrations($migrations) ->handleRequest() diff --git a/library/Director/Dashboard/Dashboard.php b/library/Director/Dashboard/Dashboard.php index ced3ef8a..a01c302f 100644 --- a/library/Director/Dashboard/Dashboard.php +++ b/library/Director/Dashboard/Dashboard.php @@ -58,11 +58,11 @@ abstract class Dashboard extends Html implements Countable protected function addDescription($description) { if ($description !== null) { - $this->add( - Html::tag('p', null, HtmlString::create( - nl2br(Util::escapeForHtml($description))) - ) - ); + $this->add(Html::tag( + 'p', + null, + HtmlString::create(nl2br(Util::escapeForHtml($description))) + )); } return $this; diff --git a/library/Director/Web/Table/ObjectsTable.php b/library/Director/Web/Table/ObjectsTable.php index 303a036f..e0522847 100644 --- a/library/Director/Web/Table/ObjectsTable.php +++ b/library/Director/Web/Table/ObjectsTable.php @@ -156,12 +156,14 @@ class ObjectsTable extends QueryBasedTable $type = $this->getType(); $object = IcingaObject::createByType($type); $table = $object->getTableName(); - $query = $this->applyRestrictions($this->db()->select() - ->from( - ['o' => $table], - $this->getColumns() - ) - ->order('o.object_name') + $query = $this->applyRestrictions( + $this->db() + ->select() + ->from( + ['o' => $table], + $this->getColumns() + ) + ->order('o.object_name') ); return $this->applyObjectTypeFilter($query); diff --git a/library/Director/Web/Tree/TemplateTreeRenderer.php b/library/Director/Web/Tree/TemplateTreeRenderer.php index 654b775a..42d54ec8 100644 --- a/library/Director/Web/Tree/TemplateTreeRenderer.php +++ b/library/Director/Web/Tree/TemplateTreeRenderer.php @@ -61,7 +61,7 @@ class TemplateTreeRenderer extends BaseElement } if ($level === 0) { - $li->add( Html::tag('a', [ + $li->add(Html::tag('a', [ 'name' => 'Templates', 'class' => 'icon-globe' ], $tree['name']));