fix(uri): fix Uri to origin_form when path is '*'

This commit is contained in:
Sean McArthur
2017-04-05 13:50:29 -07:00
parent cb1927553e
commit 5d3499e036
2 changed files with 17 additions and 22 deletions

View File

@@ -1,7 +1,7 @@
use std::ops::Deref;
use std::str;
use bytes::{Bytes, BytesMut};
use bytes::Bytes;
#[derive(Debug, Clone, PartialEq, Eq, Hash)]
pub struct ByteStr(Bytes);
@@ -38,19 +38,6 @@ impl Deref for ByteStr {
}
}
impl From<ByteStr> for Bytes {
fn from(s: ByteStr) -> Bytes {
s.0
}
}
impl From<ByteStr> for BytesMut {
fn from(s: ByteStr) -> BytesMut {
s.0.into()
}
}
impl<'a> From<&'a str> for ByteStr {
fn from(s: &'a str) -> ByteStr {
ByteStr(Bytes::from(s))