@@ -256,7 +256,7 @@ discard block |
||
| 256 | 256 | $foreignKey = $foreignKey ?? $this->assumeForeignKey($related); |
| 257 | 257 | |
| 258 | 258 | $builder = (new Builder())->setClass($related) |
| 259 | - ->setClient($this->getClient()); |
|
| 259 | + ->setClient($this->getClient()); |
|
| 260 | 260 | |
| 261 | 261 | return new BelongsTo($builder, $this, $foreignKey); |
| 262 | 262 | } |
@@ -276,8 +276,8 @@ discard block |
||
| 276 | 276 | $foreignKey = $foreignKey ?? $this->assumeForeignKey($related); |
| 277 | 277 | |
| 278 | 278 | $builder = (new Builder())->setClass($related) |
| 279 | - ->setClient($this->getClient()) |
|
| 280 | - ->setParent($this); |
|
| 279 | + ->setClient($this->getClient()) |
|
| 280 | + ->setParent($this); |
|
| 281 | 281 | |
| 282 | 282 | return new ChildOf($builder, $this, $foreignKey); |
| 283 | 283 | } |
@@ -309,7 +309,7 @@ discard block |
||
| 309 | 309 | |
| 310 | 310 | try { |
| 311 | 311 | $this->getClient() |
| 312 | - ->delete($this->getPath($this->getKey())); |
|
| 312 | + ->delete($this->getPath($this->getKey())); |
|
| 313 | 313 | |
| 314 | 314 | return true; |
| 315 | 315 | } catch (GuzzleException $e) { |
@@ -509,7 +509,7 @@ discard block |
||
| 509 | 509 | public function givenOne($related, $attributes, $reset = false): Model |
| 510 | 510 | { |
| 511 | 511 | return (new $related([], $this->parentModel))->setClient($this->getClient()) |
| 512 | - ->newFromBuilder($reset ? reset($attributes) : $attributes); |
|
| 512 | + ->newFromBuilder($reset ? reset($attributes) : $attributes); |
|
| 513 | 513 | } |
| 514 | 514 | |
| 515 | 515 | /** |
@@ -524,8 +524,8 @@ discard block |
||
| 524 | 524 | public function hasMany($related): HasMany |
| 525 | 525 | { |
| 526 | 526 | $builder = (new Builder())->setClass($related) |
| 527 | - ->setClient($this->getClient()) |
|
| 528 | - ->setParent($this); |
|
| 527 | + ->setClient($this->getClient()) |
|
| 528 | + ->setParent($this); |
|
| 529 | 529 | |
| 530 | 530 | return new HasMany($builder, $this); |
| 531 | 531 | } |
@@ -684,7 +684,7 @@ discard block |
||
| 684 | 684 | } |
| 685 | 685 | |
| 686 | 686 | $response = $this->getClient() |
| 687 | - ->post($this->getPath(), [$this->toArray()]); |
|
| 687 | + ->post($this->getPath(), [$this->toArray()]); |
|
| 688 | 688 | |
| 689 | 689 | $this->exists = true; |
| 690 | 690 | |