@@ -44,8 +44,7 @@ |
||
| 44 | 44 | $this->insert(); |
| 45 | 45 | |
| 46 | 46 | $mapper->fireEvent('created', $entity, false); |
| 47 | - } |
|
| 48 | - else if ($this->aggregate->isDirty()) { |
|
| 47 | + } else if ($this->aggregate->isDirty()) { |
|
| 49 | 48 | if ($mapper->fireEvent('updating', $entity) === false) { |
| 50 | 49 | return false; |
| 51 | 50 | } |
@@ -129,8 +129,7 @@ |
||
| 129 | 129 | if ($this->hasSetMutator($key)) { |
| 130 | 130 | $method = 'set' . $this->getMutatorMethod($key); |
| 131 | 131 | $this->attributes[$key] = $this->$method($attribute); |
| 132 | - } |
|
| 133 | - else { |
|
| 132 | + } else { |
|
| 134 | 133 | $this->attributes[$key] = $attribute; |
| 135 | 134 | } |
| 136 | 135 | } |
@@ -129,8 +129,7 @@ |
||
| 129 | 129 | if ($this->hasSetMutator($key)) { |
| 130 | 130 | $method = 'set' . $this->getMutatorMethod($key); |
| 131 | 131 | $this->attributes[$key] = $this->$method($attribute); |
| 132 | - } |
|
| 133 | - else { |
|
| 132 | + } else { |
|
| 134 | 133 | $this->attributes[$key] = $attribute; |
| 135 | 134 | } |
| 136 | 135 | } |
@@ -221,8 +221,7 @@ |
||
| 221 | 221 | { |
| 222 | 222 | if(array_key_exists($key, $this->virtualAttributes)) { |
| 223 | 223 | return $this->virtualAttributes[$key]; |
| 224 | - } |
|
| 225 | - else { |
|
| 224 | + } else { |
|
| 226 | 225 | return null; |
| 227 | 226 | } |
| 228 | 227 | } |
@@ -129,8 +129,7 @@ |
||
| 129 | 129 | if ($this->hasSetMutator($key)) { |
| 130 | 130 | $method = 'set' . $this->getMutatorMethod($key); |
| 131 | 131 | $this->attributes[$key] = $this->$method($attribute); |
| 132 | - } |
|
| 133 | - else { |
|
| 132 | + } else { |
|
| 134 | 133 | $this->attributes[$key] = $attribute; |
| 135 | 134 | } |
| 136 | 135 | } |
@@ -94,8 +94,7 @@ discard block |
||
| 94 | 94 | // we'll set the relationship to null |
| 95 | 95 | if (! $this->relationNeedsProxy($relation, $attributes)) { |
| 96 | 96 | $proxies[$relation] = null; |
| 97 | - } |
|
| 98 | - else { |
|
| 97 | + } else { |
|
| 99 | 98 | $targetClass = $this->entityMap->getTargettedClass($relation); |
| 100 | 99 | $proxies[$relation] = $this->proxyFactory->make($this->getObject(), $relation, $targetClass); |
| 101 | 100 | } |
@@ -141,7 +140,9 @@ discard block |
||
| 141 | 140 | |
| 142 | 141 | $localKey = $this->entityMap->getLocalKeys($relation); |
| 143 | 142 | |
| 144 | - if(is_null($localKey)) return true; |
|
| 143 | + if(is_null($localKey)) { |
|
| 144 | + return true; |
|
| 145 | + } |
|
| 145 | 146 | |
| 146 | 147 | if(is_array($localKey)) { |
| 147 | 148 | $localKey = $localKey['id']; |
@@ -50,7 +50,9 @@ |
||
| 50 | 50 | */ |
| 51 | 51 | public function initializeProxy() : bool |
| 52 | 52 | { |
| 53 | - if($this->isProxyInitialized() ) return true; |
|
| 53 | + if($this->isProxyInitialized() ) { |
|
| 54 | + return true; |
|
| 55 | + } |
|
| 54 | 56 | |
| 55 | 57 | $relation = $this->relationshipMethod; |
| 56 | 58 | $entity = $this->parentEntity; |