@@ -187,7 +187,7 @@ discard block |
||
187 | 187 | return 0; |
188 | 188 | } |
189 | 189 | |
190 | - if(($condition = $this->getOldPrimaryKey(true)) !== $this->getPrimaryKey(true)) { |
|
190 | + if (($condition = $this->getOldPrimaryKey(true)) !== $this->getPrimaryKey(true)) { |
|
191 | 191 | // TODO Change DN |
192 | 192 | // static::getDb()->rename($condition, $newRdn, $newParent, true); |
193 | 193 | // if (!$this->refresh()){ |
@@ -197,12 +197,12 @@ discard block |
||
197 | 197 | } |
198 | 198 | |
199 | 199 | foreach ($values as $key => $value) { |
200 | - if($key == 'dn'){ |
|
200 | + if ($key == 'dn') { |
|
201 | 201 | continue; |
202 | 202 | } |
203 | - if(empty ($this->getOldAttribute($key)) && $value === ''){ |
|
203 | + if (empty ($this->getOldAttribute($key)) && $value === '') { |
|
204 | 204 | unset($values[$key]); |
205 | - } else if($value === ''){ |
|
205 | + } else if ($value === '') { |
|
206 | 206 | $attributes[] = ['attrib' => $key, 'modtype' => LDAP_MODIFY_BATCH_REMOVE]; |
207 | 207 | } else if (empty ($this->getOldAttribute($key))) { |
208 | 208 | $attributes[] = ['attrib' => $key, 'modtype' => LDAP_MODIFY_BATCH_ADD, 'values' => is_array($value) ? $value : [$value]]; |
@@ -245,7 +245,7 @@ discard block |
||
245 | 245 | */ |
246 | 246 | public static function updateAll($attributes, $condition = '') |
247 | 247 | { |
248 | - if(is_array($condition)){ |
|
248 | + if (is_array($condition)) { |
|
249 | 249 | $condition = $condition['dn']; |
250 | 250 | } |
251 | 251 |