@@ -83,7 +83,7 @@ discard block |
||
83 | 83 | |
84 | 84 | if (strpos(strtolower($name), "where") === false){ |
85 | 85 | $method = 'where'.ucfirst($name); |
86 | - }else{ |
|
86 | + } else{ |
|
87 | 87 | $method = lcfirst($name); |
88 | 88 | } |
89 | 89 | |
@@ -129,13 +129,13 @@ discard block |
||
129 | 129 | } |
130 | 130 | return $this->where($key, $value); |
131 | 131 | } |
132 | - }else{ |
|
132 | + } else{ |
|
133 | 133 | $criteria = $this->validate_criteria($criteria); |
134 | 134 | $value = $this->parse_value($value); |
135 | 135 | |
136 | 136 | if($value === null || $value === ''){ |
137 | 137 | $this->query->push([$criteria]); |
138 | - }else{ |
|
138 | + } else{ |
|
139 | 139 | $this->query->push([$criteria, $value]); |
140 | 140 | } |
141 | 141 | } |
@@ -150,7 +150,9 @@ discard block |
||
150 | 150 | */ |
151 | 151 | public function orWhere(\Closure $closure = null) { |
152 | 152 | $this->query->push(['OR']); |
153 | - if($closure !== null) $closure($this); |
|
153 | + if($closure !== null) { |
|
154 | + $closure($this); |
|
155 | + } |
|
154 | 156 | |
155 | 157 | return $this; |
156 | 158 | } |
@@ -162,7 +164,9 @@ discard block |
||
162 | 164 | */ |
163 | 165 | public function andWhere(\Closure $closure = null) { |
164 | 166 | $this->query->push(['AND']); |
165 | - if($closure !== null) $closure($this); |
|
167 | + if($closure !== null) { |
|
168 | + $closure($this); |
|
169 | + } |
|
166 | 170 | |
167 | 171 | return $this; |
168 | 172 | } |