Completed
Pull Request — master (#38)
by
unknown
08:54
created
src/SortableTrait.php 1 patch
Spacing   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -11,7 +11,7 @@  discard block
 block discarded – undo
11 11
 {
12 12
     public static function bootSortableTrait()
13 13
     {
14
-        static::creating(function ($model) {
14
+        static::creating(function($model) {
15 15
             if ($model instanceof Sortable && $model->shouldSortWhenCreating()) {
16 16
                 $model->setHighestOrderNumber();
17 17
             }
@@ -67,7 +67,7 @@  discard block
 block discarded – undo
67 67
      */
68 68
     public static function setNewOrder($ids, int $startOrder = 1)
69 69
     {
70
-        if (! is_array($ids) && ! $ids instanceof ArrayAccess) {
70
+        if (!is_array($ids) && !$ids instanceof ArrayAccess) {
71 71
             throw new InvalidArgumentException('You must pass an array or ArrayAccess object to setNewOrder');
72 72
         }
73 73
 
@@ -90,7 +90,7 @@  discard block
 block discarded – undo
90 90
     {
91 91
         if (
92 92
             isset($this->sortable['order_column_name']) &&
93
-            ! empty($this->sortable['order_column_name'])
93
+            !empty($this->sortable['order_column_name'])
94 94
         ) {
95 95
             return $this->sortable['order_column_name'];
96 96
         }
@@ -101,7 +101,7 @@  discard block
 block discarded – undo
101 101
     public function determineSortScope() {
102 102
         if (
103 103
             isset($this->sortable['sort_scope']) &&
104
-            ! empty($this->sortable['sort_scope'])
104
+            !empty($this->sortable['sort_scope'])
105 105
         ) {
106 106
             return $this->sortable['sort_scope'];
107 107
         }
@@ -141,7 +141,7 @@  discard block
 block discarded – undo
141 141
 
142 142
         $swapWithModel = $swapWithModel->first();
143 143
 
144
-        if (! $swapWithModel) {
144
+        if (!$swapWithModel) {
145 145
             return $this;
146 146
         }
147 147
 
@@ -167,7 +167,7 @@  discard block
 block discarded – undo
167 167
 
168 168
         $swapWithModel = $swapWithModel->first();
169 169
 
170
-        if (! $swapWithModel) {
170
+        if (!$swapWithModel) {
171 171
             return $this;
172 172
         }
173 173
 
Please login to merge, or discard this patch.