/**
  * @return mixed
  */
 public function postAdd()
 {
     Coanda::checkAccess('webforms', 'edit');
     if (Input::has('cancel') && Input::get('cancel') == 'true') {
         return Redirect::to(Coanda::adminUrl('forms'));
     }
     try {
         $form = $this->webFormsRepository->createForm(Input::all());
         return Redirect::to(Coanda::adminUrl('forms/edit/' . $form->id));
     } catch (ValidationException $exception) {
         return Redirect::to(Coanda::adminUrl('forms/add'))->with('error', true)->with('invalid_fields', $exception->getInvalidFields())->withInput();
     }
 }