mirror of
https://github.com/flarum/framework.git
synced 2025-02-01 05:22:17 +08:00
Check that included
array exists (#132)
This commit is contained in:
parent
95fc846c04
commit
a6695e10cd
|
@ -82,7 +82,7 @@ class Tag
|
|||
$tagsDocument = $this->getTagsDocument($request, $slug);
|
||||
|
||||
$apiDocument->included[] = $tagsDocument->data;
|
||||
$includedTags = $tagsDocument->included;
|
||||
$includedTags = $tagsDocument->included ?? [];
|
||||
foreach ((array) $includedTags as $includedTag) {
|
||||
$apiDocument->included[] = $includedTag;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue
Block a user