@@ -57,8 +57,8 @@ discard block |
||
| 57 | 57 | $setter = $class->addMethod(Str::methodName($name . ' Attribute', 'set')); |
| 58 | 58 | $setter->setVisibility(ClassType::VISIBILITY_PROTECTED); |
| 59 | 59 | $setter->addParameter('value') |
| 60 | - ->setNullable($this->property->getNullable()) |
|
| 61 | - ->setType($alias); |
|
| 60 | + ->setNullable($this->property->getNullable()) |
|
| 61 | + ->setType($alias); |
|
| 62 | 62 | $setter->setBody($body); |
| 63 | 63 | $setter->setComment($this->property->getSetterComment()); |
| 64 | 64 | } |
@@ -76,8 +76,8 @@ discard block |
||
| 76 | 76 | $setter = $class->addMethod(Str::methodName($name, 'set')); |
| 77 | 77 | $setter->setVisibility(ClassType::VISIBILITY_PUBLIC); |
| 78 | 78 | $setter->addParameter('value') |
| 79 | - ->setType($type) |
|
| 80 | - ->setNullable($this->property->getNullable()); |
|
| 79 | + ->setType($type) |
|
| 80 | + ->setNullable($this->property->getNullable()); |
|
| 81 | 81 | $setter->setBody($body); |
| 82 | 82 | $setter->setComment($this->property->getSetterComment()); |
| 83 | 83 | } |
@@ -135,11 +135,11 @@ |
||
| 135 | 135 | $relation = $this->mapper->getRelation($name); |
| 136 | 136 | if ($relation instanceof ToOneInterface && |
| 137 | 137 | isset($attributes[$name]) && |
| 138 | - ! is_object($attributes[$name])) { |
|
| 138 | + !is_object($attributes[$name])) { |
|
| 139 | 139 | $attributes[$name] = $relation->getForeignMapper()->newEntity($attributes[$name]); |
| 140 | 140 | } elseif ($relation instanceof ToManyInterface && |
| 141 | - ! $relation instanceof ToOneInterface |
|
| 142 | - && ( ! isset($attributes[$name]) || is_array($attributes[$name]))) { |
|
| 141 | + !$relation instanceof ToOneInterface |
|
| 142 | + && (!isset($attributes[$name]) || is_array($attributes[$name]))) { |
|
| 143 | 143 | /** |
| 144 | 144 | * we also need to check against ToOneInterface because OneToOne relation extends |
| 145 | 145 | * OneToMany which implements ToOneInterface |
@@ -130,11 +130,11 @@ |
||
| 130 | 130 | $relation = $this->mapper->getRelation($name); |
| 131 | 131 | if ($relation instanceof ToOneInterface && |
| 132 | 132 | isset($attributes[$name]) && |
| 133 | - ! is_object($attributes[$name])) { |
|
| 133 | + !is_object($attributes[$name])) { |
|
| 134 | 134 | $attributes[$name] = $relation->getForeignMapper()->newEntity($attributes[$name]); |
| 135 | 135 | } elseif ($relation instanceof ToManyInterface && |
| 136 | - ! $relation instanceof ToOneInterface |
|
| 137 | - && ( ! isset($attributes[$name]) || is_array($attributes[$name]))) { |
|
| 136 | + !$relation instanceof ToOneInterface |
|
| 137 | + && (!isset($attributes[$name]) || is_array($attributes[$name]))) { |
|
| 138 | 138 | /** |
| 139 | 139 | * we also need to check against ToOneInterface because OneToOne relation extends |
| 140 | 140 | * OneToMany which implements ToOneInterface |