public function update(ComponentGroup $group)
    {
        try {
            $group = execute(new UpdateComponentGroupCommand(
                $group,
                Binput::get('name'),
                Binput::get('order'),
                Binput::get('collapsed'),
                Binput::get('visible')
            ));
        } catch (QueryException $e) {
            throw new BadRequestHttpException();
        }

        return $this->item($group);
    }