Completed
Push — master ( 36b244...7a8808 )
by Travis
09:14
created
src/NukaCode/Menu/MenuServiceProvider.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -39,7 +39,7 @@
 block discarded – undo
39 39
      */
40 40
     protected function shareWithApp()
41 41
     {
42
-        $this->app->singleton('menu', function () {
42
+        $this->app->singleton('menu', function() {
43 43
             return new Container();
44 44
         });
45 45
     }
Please login to merge, or discard this patch.
src/NukaCode/Menu/Container.php 2 patches
Spacing   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -55,7 +55,7 @@  discard block
 block discarded – undo
55 55
      */
56 56
     public function exists($menuName)
57 57
     {
58
-        return (bool)$this->getMenuObject($menuName);
58
+        return (bool) $this->getMenuObject($menuName);
59 59
     }
60 60
 
61 61
     /**
@@ -85,7 +85,7 @@  discard block
 block discarded – undo
85 85
 
86 86
         $menu = $this->getMenuObject($menuName);
87 87
 
88
-        if (! $menu) {
88
+        if (!$menu) {
89 89
             throw new \Exception("Menu {$menuName} not found.");
90 90
         }
91 91
 
@@ -141,7 +141,7 @@  discard block
 block discarded – undo
141 141
      */
142 142
     private function updateActive()
143 143
     {
144
-        $this->each(function ($item) {
144
+        $this->each(function($item) {
145 145
             if (isset($item->links)) {
146 146
                 $this->makeActive($item);
147 147
             }
@@ -154,7 +154,7 @@  discard block
 block discarded – undo
154 154
      */
155 155
     private function makeActive($item, $parent = null)
156 156
     {
157
-        $item->links->each(function ($link) use ($item, $parent) {
157
+        $item->links->each(function($link) use ($item, $parent) {
158 158
             if ($link->slug == $this->active) {
159 159
                 $this->makeParentActive($parent);
160 160
                 $this->makeParentActive($item);
@@ -173,7 +173,7 @@  discard block
 block discarded – undo
173 173
      */
174 174
     private function makeParentActive($parent)
175 175
     {
176
-        if (! is_null($parent)
176
+        if (!is_null($parent)
177 177
             && method_exists($parent, 'activeParentage')
178 178
             && $parent->activeParentage()
179 179
         ) {
Please login to merge, or discard this patch.
Braces   +1 added lines, -2 removed lines patch added patch discarded remove patch
@@ -7,8 +7,7 @@
 block discarded – undo
7 7
  *
8 8
  * @package NukaCode\Menu
9 9
  */
10
-class Container extends Collection
11
-{
10
+class Container extends Collection {
12 11
 
13 12
     /**
14 13
      * The slug to set to active during render
Please login to merge, or discard this patch.