Skip to content

Commit

Permalink
[TM-921] Make sure to include names when copying over tree species.
Browse files Browse the repository at this point in the history
  • Loading branch information
roguenet committed May 23, 2024
1 parent 5c4dd0f commit 89aef7b
Showing 1 changed file with 1 addition and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -95,6 +95,7 @@ public function __invoke(Request $request): EntityWithSchemaResource
foreach ($projectPitch->treeSpecies()->get() as $treeSpecies) {
$project->treeSpecies()->create([
'collection' => $treeSpecies->collection ?? TreeSpecies::COLLECTION_PRIMARY,
'name' => $treeSpecies->name,
'amount' => $treeSpecies->amount,
]);
}
Expand Down

0 comments on commit 89aef7b

Please sign in to comment.