{"action":"created","issue":{"url":"https://api.github.com/repos/erikras/redux-form/issues/751","repository_url":"https://api.github.com/repos/erikras/redux-form","labels_url":"https://api.github.com/repos/erikras/redux-form/issues/751/labels{/name}","comments_url":"https://api.github.com/repos/erikras/redux-form/issues/751/comments","events_url":"https://api.github.com/repos/erikras/redux-form/issues/751/events","html_url":"https://github.com/erikras/redux-form/issues/751","id":141848680,"number":751,"title":"Ignoring certain validation rules at final submit","user":{"login":"rasmuswoelk","id":640976,"avatar_url":"https://avatars.githubusercontent.com/u/640976?v=3","gravatar_id":"","url":"https://api.github.com/users/rasmuswoelk","html_url":"https://github.com/rasmuswoelk","followers_url":"https://api.github.com/users/rasmuswoelk/followers","following_url":"https://api.github.com/users/rasmuswoelk/following{/other_user}","gists_url":"https://api.github.com/users/rasmuswoelk/gists{/gist_id}","starred_url":"https://api.github.com/users/rasmuswoelk/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/rasmuswoelk/subscriptions","organizations_url":"https://api.github.com/users/rasmuswoelk/orgs","repos_url":"https://api.github.com/users/rasmuswoelk/repos","events_url":"https://api.github.com/users/rasmuswoelk/events{/privacy}","received_events_url":"https://api.github.com/users/rasmuswoelk/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":3,"created_at":"2016-03-18T12:08:29Z","updated_at":"2016-03-21T21:55:47Z","closed_at":null,"body":"Hi\r\n\r\nI'm creating a checkout form where I \"password\" and \"password again\" fields among a lot of other fields of course. When the user type in an email, the form will show a password field only and upon sign in the form will reinitialize with the users own values from his/her account. (I'm not using Redux Form to submit here - just a simple onClick function that send a post request to my server and then reload the user-reducer).\r\n\r\nHowever if the user wants to create an account then I show the before mentioned \"password\" and \"password again\" fields.\r\n\r\nThe problem is that I have both password and password again in the validation function and it will try to validate both fields - even if the user is signed in to an account and these field aren't to be found in the form.\r\n\r\nThe question is: Can I ignore some validation rules upon submit when the user is signed in? But still use the validation rules when the user decides to create an account? And also can I add my own custom validation error from within my component somewhere (not asyncvalidation).\r\n\r\nScreenshot of form: \r\nhttps://www.dropbox.com/s/yx48mnbz6rxnvit/Sk%C3%A6rmbillede%202016-03-18%2013.06.16.png?dl=0\r\n\r\nI love Redux Form and hope you can provide a solution or work-around for this. If this isn't the appropriate place for such question then you can just close the issue :-)"},"comment":{"url":"https://api.github.com/repos/erikras/redux-form/issues/comments/199503284","html_url":"https://github.com/erikras/redux-form/issues/751#issuecomment-199503284","issue_url":"https://api.github.com/repos/erikras/redux-form/issues/751","id":199503284,"user":{"login":"rasmuswoelk","id":640976,"avatar_url":"https://avatars.githubusercontent.com/u/640976?v=3","gravatar_id":"","url":"https://api.github.com/users/rasmuswoelk","html_url":"https://github.com/rasmuswoelk","followers_url":"https://api.github.com/users/rasmuswoelk/followers","following_url":"https://api.github.com/users/rasmuswoelk/following{/other_user}","gists_url":"https://api.github.com/users/rasmuswoelk/gists{/gist_id}","starred_url":"https://api.github.com/users/rasmuswoelk/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/rasmuswoelk/subscriptions","organizations_url":"https://api.github.com/users/rasmuswoelk/orgs","repos_url":"https://api.github.com/users/rasmuswoelk/repos","events_url":"https://api.github.com/users/rasmuswoelk/events{/privacy}","received_events_url":"https://api.github.com/users/rasmuswoelk/received_events","type":"User","site_admin":false},"created_at":"2016-03-21T21:55:46Z","updated_at":"2016-03-21T21:55:46Z","body":"Ah I get your answer now. I could add a \"signedin\" field to my fields which I can update with a value from within my component and then check in the validator if it is set or not. That's definitely a solution!"}}