1
0
mirror of https://github.com/flarum/core.git synced 2025-07-17 23:01:17 +02:00

Prevent error if no input is given in create actions

This commit is contained in:
Toby Zerner
2015-11-23 14:15:30 +10:30
parent a61929730e
commit 262a934747
4 changed files with 4 additions and 4 deletions

View File

@@ -41,7 +41,7 @@ class CreateGroupController extends AbstractCreateController
protected function data(ServerRequestInterface $request, Document $document)
{
return $this->bus->dispatch(
new CreateGroup($request->getAttribute('actor'), array_get($request->getParsedBody(), 'data'))
new CreateGroup($request->getAttribute('actor'), array_get($request->getParsedBody(), 'data', []))
);
}
}