@@ -38,7 +38,7 @@ discard block |
||
| 38 | 38 | |
| 39 | 39 | protected function getLimitClause() : string |
| 40 | 40 | { |
| 41 | - if (! $this->query->limit) { |
|
| 41 | + if (!$this->query->limit) { |
|
| 42 | 42 | return ''; |
| 43 | 43 | } |
| 44 | 44 | |
@@ -52,7 +52,7 @@ discard block |
||
| 52 | 52 | |
| 53 | 53 | protected function getOffsetClause() : string |
| 54 | 54 | { |
| 55 | - if (! $this->query->offset) { |
|
| 55 | + if (!$this->query->offset) { |
|
| 56 | 56 | return ''; |
| 57 | 57 | } |
| 58 | 58 | |
@@ -64,12 +64,12 @@ discard block |
||
| 64 | 64 | $orders = collect($this->query->orders); |
| 65 | 65 | |
| 66 | 66 | return $orders |
| 67 | - ->reduce(function ($carry, $order) { |
|
| 67 | + ->reduce(function($carry, $order) { |
|
| 68 | 68 | if (($order['type'] ?? '') === 'Raw') { |
| 69 | - return $carry . '_orderByRaw_' . str_slug($order['sql']); |
|
| 69 | + return $carry.'_orderByRaw_'.str_slug($order['sql']); |
|
| 70 | 70 | } |
| 71 | 71 | |
| 72 | - return $carry . '_orderBy_' . $order['column'] . '_' . $order['direction']; |
|
| 72 | + return $carry.'_orderBy_'.$order['column'].'_'.$order['direction']; |
|
| 73 | 73 | }) |
| 74 | 74 | ?: ''; |
| 75 | 75 | } |
@@ -80,7 +80,7 @@ discard block |
||
| 80 | 80 | return ''; |
| 81 | 81 | } |
| 82 | 82 | |
| 83 | - return '_' . implode('_', $columns); |
|
| 83 | + return '_'.implode('_', $columns); |
|
| 84 | 84 | } |
| 85 | 85 | |
| 86 | 86 | protected function getTypeClause($where) : string |
@@ -93,14 +93,14 @@ discard block |
||
| 93 | 93 | protected function getValuesClause(array $where = null) : string |
| 94 | 94 | { |
| 95 | 95 | return is_array(array_get($where, 'values')) |
| 96 | - ? '_' . implode('_', $where['values']) |
|
| 96 | + ? '_'.implode('_', $where['values']) |
|
| 97 | 97 | : ''; |
| 98 | 98 | } |
| 99 | 99 | |
| 100 | 100 | protected function getWhereClauses(array $wheres = []) : string |
| 101 | 101 | { |
| 102 | 102 | return $this->getWheres($wheres) |
| 103 | - ->reduce(function ($carry, $where) { |
|
| 103 | + ->reduce(function($carry, $where) { |
|
| 104 | 104 | $value = $this->getNestedClauses($where); |
| 105 | 105 | $value .= $this->getColumnClauses($where); |
| 106 | 106 | $value .= $this->getRawClauses($where); |
@@ -113,11 +113,11 @@ discard block |
||
| 113 | 113 | |
| 114 | 114 | protected function getNestedClauses(array $where) : string |
| 115 | 115 | { |
| 116 | - if (! in_array($where['type'], ['Exists', 'Nested', 'NotExists'])) { |
|
| 116 | + if (!in_array($where['type'], ['Exists', 'Nested', 'NotExists'])) { |
|
| 117 | 117 | return ''; |
| 118 | 118 | } |
| 119 | 119 | |
| 120 | - return '_' . strtolower($where['type']) . $this->getWhereClauses($where['query']->wheres); |
|
| 120 | + return '_'.strtolower($where['type']).$this->getWhereClauses($where['query']->wheres); |
|
| 121 | 121 | } |
| 122 | 122 | |
| 123 | 123 | protected function getColumnClauses(array $where) : string |
@@ -135,7 +135,7 @@ discard block |
||
| 135 | 135 | return ''; |
| 136 | 136 | } |
| 137 | 137 | |
| 138 | - return "_{$where['boolean']}_" . str_slug($where['sql']); |
|
| 138 | + return "_{$where['boolean']}_".str_slug($where['sql']); |
|
| 139 | 139 | } |
| 140 | 140 | |
| 141 | 141 | protected function getOtherClauses(array $where, string $carry = null) : string |
@@ -170,6 +170,6 @@ discard block |
||
| 170 | 170 | return ''; |
| 171 | 171 | } |
| 172 | 172 | |
| 173 | - return '-' . implode('-', $eagerLoads->keys()->toArray()); |
|
| 173 | + return '-'.implode('-', $eagerLoads->keys()->toArray()); |
|
| 174 | 174 | } |
| 175 | 175 | } |