protected function assertSubmitedFormIsValid(Request $request, FormInterface $form)
    {
        $form->submit(
            $this->getRequestData($request),
            $request->getMethod() !== 'PATCH'
        );

        if (!$valid = $form->isValid()) {
            throw new ValidationException(
                $form->getData(),
                $form->getErrors(true, true) // deep & flattened
            );
        }
    }