expectsJson()) { throw new ResourceException('Validation Error', $errors); } return redirect()->to($this->getRedirectUrl())->withInput($request->input())->withErrors($errors, $this->errorBag()); } }