Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use the new form_urlencoded crate instead of url #74

Merged
merged 1 commit into from
Aug 4, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -18,9 +18,9 @@ test = false

[dependencies]
dtoa = "0.4.0"
form_urlencoded = "1.0.0"
itoa = "0.4.0"
serde = "1.0.0"
url = "2.0.0"

[dev-dependencies]
serde_derive = "1.0"
4 changes: 2 additions & 2 deletions src/de.rs
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
//! Deserialization support for the `application/x-www-form-urlencoded` format.

use form_urlencoded::parse;
use form_urlencoded::Parse as UrlEncodedParse;
use serde::de::value::MapDeserializer;
use serde::de::Error as de_Error;
use serde::de::{self, IntoDeserializer};
use std::borrow::Cow;
use std::io::Read;
use url::form_urlencoded::parse;
use url::form_urlencoded::Parse as UrlEncodedParse;

#[doc(inline)]
pub use serde::de::value::Error;
Expand Down
2 changes: 1 addition & 1 deletion src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -3,10 +3,10 @@
#![warn(unused_extern_crates)]

extern crate dtoa;
extern crate form_urlencoded;
extern crate itoa;
#[macro_use]
extern crate serde;
extern crate url;

pub mod de;
pub mod ser;
Expand Down
4 changes: 2 additions & 2 deletions src/ser/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -5,13 +5,13 @@ mod pair;
mod part;
mod value;

use form_urlencoded::Serializer as UrlEncodedSerializer;
use form_urlencoded::Target as UrlEncodedTarget;
use serde::ser;
use std::borrow::Cow;
use std::error;
use std::fmt;
use std::str;
use url::form_urlencoded::Serializer as UrlEncodedSerializer;
use url::form_urlencoded::Target as UrlEncodedTarget;

/// Serializes a value into a `application/x-www-form-urlencoded` `String` buffer.
///
Expand Down
4 changes: 2 additions & 2 deletions src/ser/pair.rs
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
use form_urlencoded::Serializer as UrlEncodedSerializer;
use form_urlencoded::Target as UrlEncodedTarget;
use ser::key::KeySink;
use ser::part::PartSerializer;
use ser::value::ValueSink;
use ser::Error;
use serde::ser;
use std::borrow::Cow;
use std::mem;
use url::form_urlencoded::Serializer as UrlEncodedSerializer;
use url::form_urlencoded::Target as UrlEncodedTarget;

pub struct PairSerializer<'input, 'target, Target: 'target + UrlEncodedTarget> {
urlencoder: &'target mut UrlEncodedSerializer<'input, Target>,
Expand Down
4 changes: 2 additions & 2 deletions src/ser/value.rs
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
use form_urlencoded::Serializer as UrlEncodedSerializer;
use form_urlencoded::Target as UrlEncodedTarget;
use ser::part::{PartSerializer, Sink};
use ser::Error;
use serde::ser::Serialize;
use std::str;
use url::form_urlencoded::Serializer as UrlEncodedSerializer;
use url::form_urlencoded::Target as UrlEncodedTarget;

pub struct ValueSink<'input, 'key, 'target, Target>
where
Expand Down