Skip to content

Commit 160e759

Browse files
authored
Merge pull request #17 from trms/#14-bulletin-tags-endpoint-wont-accept-id-null
#14 strip out null values in model toArray
2 parents cfc0501 + f44bab5 commit 160e759

1 file changed

Lines changed: 3 additions & 0 deletions

File tree

src/Models/CarouselModel.php

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -107,6 +107,9 @@ public function toArray()
107107
->map(function($property){
108108
return $this->flattenRelationships($property);
109109
})
110+
->reject(function($property){
111+
return is_null($property);
112+
})
110113
->toArray();
111114

112115
return $properties;

0 commit comments

Comments
 (0)