Skip to content
This repository has been archived by the owner on Apr 3, 2019. It is now read-only.

chore(project): remove the validator dependency #60

Merged
merged 1 commit into from
Jun 6, 2018
Merged

Conversation

philbooth
Copy link
Contributor

Fixes #41.

Since we got the sprauncy new regex in #45, I decided to quickly whip out this dependency right away. It's been annoying me for a while.

@mozilla/fxa-devs r?

@philbooth philbooth self-assigned this Jun 6, 2018
@philbooth philbooth requested a review from a team June 6, 2018 11:16
Copy link
Contributor

@vladikoff vladikoff left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

r+

struct Email {
#[validate(email)]
#[serde(deserialize_with = "deserialize::email_address")]
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👍

@@ -43,7 +41,7 @@ struct Email {
}

impl FromData for Email {
type Error = ValidationError;
type Error = ();
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I guess this will be changed once we use the suggested error crates?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Possibly, although I think it's more contingent on a resolution to rwf2/Rocket#596 tbh.

@@ -25,9 +25,6 @@ extern crate serde;
#[macro_use]
extern crate serde_derive;
extern crate serde_json;
extern crate validator;
#[macro_use]
extern crate validator_derive;
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👍

@philbooth philbooth merged commit 44dcffd into master Jun 6, 2018
@philbooth philbooth deleted the pb/41 branch June 6, 2018 11:42
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants