Completed
Push — master ( 940c6a...aa95ad )
by Arjay
05:02
created
src/Engines/CollectionEngine.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -123,7 +123,7 @@
 block discarded – undo
123 123
                 $keyword = $this->request->keyword();
124 124
                 foreach ($this->request->searchableColumnIndex() as $index) {
125 125
                     $column = $this->getColumnName($index);
126
-                    if (! $value = Arr::get($data, $column)) {
126
+                    if (!$value = Arr::get($data, $column)) {
127 127
                         continue;
128 128
                     }
129 129
 
Please login to merge, or discard this patch.
src/Helper.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -131,7 +131,7 @@
 block discarded – undo
131 131
      */
132 132
     public static function getOrMethod($method)
133 133
     {
134
-        if (! Str::contains(Str::lower($method), 'or')) {
134
+        if (!Str::contains(Str::lower($method), 'or')) {
135 135
             return 'or' . ucfirst($method);
136 136
         }
137 137
 
Please login to merge, or discard this patch.
src/Processors/RowProcessor.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -41,8 +41,8 @@
 block discarded – undo
41 41
      */
42 42
     public function rowValue($attribute, $template)
43 43
     {
44
-        if (! empty($template)) {
45
-            if (! is_callable($template) && Arr::get($this->data, $template)) {
44
+        if (!empty($template)) {
45
+            if (!is_callable($template) && Arr::get($this->data, $template)) {
46 46
                 $this->data[$attribute] = Arr::get($this->data, $template);
47 47
             } else {
48 48
                 $this->data[$attribute] = Helper::compileContent($template, $this->data, $this->row);
Please login to merge, or discard this patch.
src/Request.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -17,9 +17,9 @@  discard block
 block discarded – undo
17 17
      */
18 18
     public function checkLegacyCode()
19 19
     {
20
-        if (! $this->get('draw') && $this->get('sEcho')) {
20
+        if (!$this->get('draw') && $this->get('sEcho')) {
21 21
             throw new Exception('DataTables legacy code is not supported! Please use DataTables 1.10++ coding convention.');
22
-        } elseif (! $this->get('draw') && ! $this->get('columns')) {
22
+        } elseif (!$this->get('draw') && !$this->get('columns')) {
23 23
             throw new Exception('Insufficient parameters');
24 24
         }
25 25
     }
@@ -63,7 +63,7 @@  discard block
 block discarded – undo
63 63
      */
64 64
     public function orderableColumns()
65 65
     {
66
-        if (! $this->isOrderable()) {
66
+        if (!$this->isOrderable()) {
67 67
             return [];
68 68
         }
69 69
 
@@ -162,6 +162,6 @@  discard block
 block discarded – undo
162 162
      */
163 163
     public function isPaginationable()
164 164
     {
165
-        return ! is_null($this->get('start')) && ! is_null($this->get('length')) && $this->get('length') != -1;
165
+        return !is_null($this->get('start')) && !is_null($this->get('length')) && $this->get('length') != -1;
166 166
     }
167 167
 }
Please login to merge, or discard this patch.
src/fallback.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -1,6 +1,6 @@  discard block
 block discarded – undo
1 1
 <?php
2 2
 
3
-if (! function_exists('config_path')) {
3
+if (!function_exists('config_path')) {
4 4
     /**
5 5
      * Get the configuration path.
6 6
      *
@@ -13,7 +13,7 @@  discard block
 block discarded – undo
13 13
     }
14 14
 }
15 15
 
16
-if (! function_exists('public_path')) {
16
+if (!function_exists('public_path')) {
17 17
     /**
18 18
      * Return the path to public dir
19 19
      *
Please login to merge, or discard this patch.
src/Processors/DataProcessor.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -115,7 +115,7 @@
 block discarded – undo
115 115
     protected function editColumns($data, $row)
116 116
     {
117 117
         foreach ($this->editColumns as $key => $value) {
118
-            $value['content']     = Helper::compileContent($value['content'], $data, $row);
118
+            $value['content'] = Helper::compileContent($value['content'], $data, $row);
119 119
             Arr::set($data, $value['name'], $value['content']);
120 120
         }
121 121
 
Please login to merge, or discard this patch.
src/Engines/BaseEngine.php 1 patch
Spacing   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -268,7 +268,7 @@  discard block
 block discarded – undo
268 268
         foreach ($joins as $join) {
269 269
             $table   = preg_split('/ as /i', $join->table);
270 270
             $names[] = $table[0];
271
-            if (isset($table[1]) && ! empty($databasePrefix) && strpos($table[1], $databasePrefix) == 0) {
271
+            if (isset($table[1]) && !empty($databasePrefix) && strpos($table[1], $databasePrefix) == 0) {
272 272
                 $names[] = preg_replace('/^' . $databasePrefix . '/', '', $table[1]);
273 273
             }
274 274
         }
@@ -284,7 +284,7 @@  discard block
 block discarded – undo
284 284
      */
285 285
     public function getQueryBuilder($instance = null)
286 286
     {
287
-        if (! $instance) {
287
+        if (!$instance) {
288 288
             $instance = $this->query;
289 289
         }
290 290
 
@@ -539,7 +539,7 @@  discard block
 block discarded – undo
539 539
         $this->totalRecords = $this->totalCount();
540 540
 
541 541
         if ($this->totalRecords) {
542
-            $this->orderRecords(! $orderFirst);
542
+            $this->orderRecords(!$orderFirst);
543 543
             $this->filterRecords();
544 544
             $this->orderRecords($orderFirst);
545 545
             $this->paginate();
@@ -556,7 +556,7 @@  discard block
 block discarded – undo
556 556
      */
557 557
     public function orderRecords($skip)
558 558
     {
559
-        if (! $skip) {
559
+        if (!$skip) {
560 560
             $this->ordering();
561 561
         }
562 562
     }
@@ -838,7 +838,7 @@  discard block
 block discarded – undo
838 838
     {
839 839
         $matches = explode(' as ', Str::lower($str));
840 840
 
841
-        if (! empty($matches)) {
841
+        if (!empty($matches)) {
842 842
             if ($wantsAlias) {
843 843
                 return array_pop($matches);
844 844
             } else {
Please login to merge, or discard this patch.
src/Html/Builder.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -307,7 +307,7 @@  discard block
 block discarded – undo
307 307
     public function columns(array $columns)
308 308
     {
309 309
         foreach ($columns as $key => $value) {
310
-            if (! is_a($value, Column::class)) {
310
+            if (!is_a($value, Column::class)) {
311 311
                 if (is_array($value)) {
312 312
                     $attributes = array_merge(['name' => $key, 'data' => $key], $this->setTitle($key, $value));
313 313
                 } else {
@@ -336,7 +336,7 @@  discard block
 block discarded – undo
336 336
      */
337 337
     public function setTitle($title, array $attributes)
338 338
     {
339
-        if (! isset($attributes['title'])) {
339
+        if (!isset($attributes['title'])) {
340 340
             $attributes['title'] = $this->getQualifiedTitle($title);
341 341
         }
342 342
 
Please login to merge, or discard this patch.
src/Engines/QueryBuilderEngine.php 1 patch
Spacing   +7 added lines, -7 removed lines patch added patch discarded remove patch
@@ -93,7 +93,7 @@  discard block
 block discarded – undo
93 93
         $myQuery = clone $this->query;
94 94
         // if its a normal query ( no union, having and distinct word )
95 95
         // replace the select with static text to improve performance
96
-        if (! Str::contains(Str::lower($myQuery->toSql()), ['union', 'having', 'distinct', 'order by', 'group by'])) {
96
+        if (!Str::contains(Str::lower($myQuery->toSql()), ['union', 'having', 'distinct', 'order by', 'group by'])) {
97 97
             $row_count = $this->connection->getQueryGrammar()->wrap('row_count');
98 98
             $myQuery->select($this->connection->raw("'1' as {$row_count}"));
99 99
         }
@@ -125,7 +125,7 @@  discard block
 block discarded – undo
125 125
                         $columnDef = $this->columnDef['filter'][$columnName];
126 126
                         // check if global search should be applied for the specific column
127 127
                         $applyGlobalSearch = count($columnDef['parameters']) == 0 || end($columnDef['parameters']) !== false;
128
-                        if (! $applyGlobalSearch) {
128
+                        if (!$applyGlobalSearch) {
129 129
                             continue;
130 130
                         }
131 131
 
@@ -297,7 +297,7 @@  discard block
 block discarded – undo
297 297
         $columns = $this->request->get('columns', []);
298 298
 
299 299
         foreach ($columns as $index => $column) {
300
-            if (! $this->request->isColumnSearchable($index)) {
300
+            if (!$this->request->isColumnSearchable($index)) {
301 301
                 continue;
302 302
             }
303 303
 
@@ -337,7 +337,7 @@  discard block
 block discarded – undo
337 337
                 $keyword         = $this->getSearchKeyword($index);
338 338
                 $caseInsensitive = $this->isCaseInsensitive();
339 339
 
340
-                if (! $caseInsensitive) {
340
+                if (!$caseInsensitive) {
341 341
                     $column = strstr($column, '(') ? $this->connection->raw($column) : $column;
342 342
                 }
343 343
 
@@ -471,7 +471,7 @@  discard block
 block discarded – undo
471 471
             $pivotPK = $model->getForeignKey();
472 472
             $pivotFK = $model->getQualifiedParentKeyName();
473 473
 
474
-            if (! in_array($pivot, $joins)) {
474
+            if (!in_array($pivot, $joins)) {
475 475
                 $this->getQueryBuilder()->leftJoin($pivot, $pivotPK, '=', $pivotFK);
476 476
             }
477 477
 
@@ -480,14 +480,14 @@  discard block
 block discarded – undo
480 480
             $tablePK = $related->getForeignKey();
481 481
             $tableFK = $related->getQualifiedKeyName();
482 482
 
483
-            if (! in_array($table, $joins)) {
483
+            if (!in_array($table, $joins)) {
484 484
                 $this->getQueryBuilder()->leftJoin($table, $pivot . '.' . $tablePK, '=', $tableFK);
485 485
             }
486 486
         } else {
487 487
             $table   = $model->getRelated()->getTable();
488 488
             $foreign = $model->getQualifiedForeignKey();
489 489
             $other   = $model->getQualifiedOtherKeyName();
490
-            if (! in_array($table, $joins)) {
490
+            if (!in_array($table, $joins)) {
491 491
                 $this->getQueryBuilder()->leftJoin($table, $foreign, '=', $other);
492 492
             }
493 493
         }
Please login to merge, or discard this patch.