Skip to content
This repository has been archived by the owner on Feb 16, 2021. It is now read-only.

Path is empty for errors from getValue(raw = true) #94

Closed
dearlordylord opened this issue Apr 4, 2015 · 1 comment
Closed

Path is empty for errors from getValue(raw = true) #94

dearlordylord opened this issue Apr 4, 2015 · 1 comment

Comments

@dearlordylord
Copy link

I create this issue not in tcomb-validation as don't have time to check this library separately. Probably it is validation library issue but might be form as well.

My goal is getting error messages (or at least information which field have an error) from getValue(true).

I have schema like

var Positive = t.subtype(t.Num, function(n) {
  return n > 0;
});

var BillingSubscriptionFormModel = t.struct({
  subscriptionType: t.enums({
    monthly: 'Monthly',
    yearly: 'Yearly'
  }),
  attendants: Positive
});

Later in code, I call created form by ref: this.refs.form.getValue(true);.

Resulting ValidationResult have ValidationErrors with empty paths.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

2 participants