Skip to content

Commit

Permalink
fix redirect
Browse files Browse the repository at this point in the history
  • Loading branch information
dignifiedquire committed Apr 10, 2020
1 parent b7b6ca2 commit 8684daf
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/redirect.rs
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ pub struct Redirect {
impl<State> Endpoint<State> for Redirect {
fn call<'a>(&'a self, _req: Request<State>) -> BoxFuture<'a, Response> {
let res = Response::new(StatusCode::TemporaryRedirect)
.set_header("location".parse().unwrap(), &self.location);
.set_header("location".parse().unwrap(), self.location.clone());
Box::pin(async move { res })
}
}

0 comments on commit 8684daf

Please sign in to comment.