Adding couple of missing commas
This commit is contained in:
parent
6395095659
commit
f129126a82
@ -93,7 +93,7 @@ impl From<hyper::error::Error> for WebappServerError {
|
||||
fn from(err: hyper::error::Error) -> Self {
|
||||
match err {
|
||||
hyper::error::Error::Io(e) => WebappServerError::IoError(e),
|
||||
e => WebappServerError::Other(e)
|
||||
e => WebappServerError::Other(e),
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -26,7 +26,7 @@ pub trait Page : Send + Sync {
|
||||
}
|
||||
|
||||
pub struct PageHandler<T : WebApp> {
|
||||
pub app: T
|
||||
pub app: T,
|
||||
}
|
||||
|
||||
impl<T: WebApp> Page for PageHandler<T> {
|
||||
@ -50,7 +50,7 @@ impl<T: WebApp> Page for PageHandler<T> {
|
||||
Err(_) => {
|
||||
println!("Error while writing response.");
|
||||
Ok(())
|
||||
}
|
||||
},
|
||||
};
|
||||
}
|
||||
}
|
||||
|
@ -47,7 +47,7 @@ impl hyper::server::Handler for RestApi {
|
||||
res.headers_mut().set(header::ContentType("application/json".parse().unwrap()));
|
||||
let _ = res.send(self.list_pages().as_bytes());
|
||||
},
|
||||
_ => ()
|
||||
_ => (),
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -75,14 +75,14 @@ impl Router {
|
||||
Some(ref host) => {
|
||||
format!("http://{}:{}{}", host.hostname, host.port.unwrap_or(80), path)
|
||||
},
|
||||
None => return None
|
||||
None => return None,
|
||||
};
|
||||
|
||||
match Url::parse(&url_string) {
|
||||
Ok(url) => Some(url),
|
||||
_ => None,
|
||||
}
|
||||
}
|
||||
},
|
||||
_ => None,
|
||||
}
|
||||
}
|
||||
@ -103,7 +103,7 @@ impl Router {
|
||||
},
|
||||
_ => {
|
||||
(None, req)
|
||||
}
|
||||
},
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user