Skip to content

Commit

Permalink
Check both cases on populate relations
Browse files Browse the repository at this point in the history
  • Loading branch information
greabock authored Jul 16, 2021
1 parent 07b5b1a commit 8677e3c
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions src/Populator.php
Original file line number Diff line number Diff line change
Expand Up @@ -123,6 +123,11 @@ protected function fillRelations(Model $model, array $data): void

foreach ($relations as $relation => $relationData) {

if ($model->isRelation($relation)) {

$this->populateRelation($model, $relation, $relationData);
}

$relation = Str::camel($relation);

if ($model->isRelation($relation)) {
Expand Down

0 comments on commit 8677e3c

Please sign in to comment.