From 09aabc7b3b23be7c4ae02dada73138b2b57a97e5 Mon Sep 17 00:00:00 2001 From: Gorm Casper Date: Wed, 4 Jul 2018 10:17:44 +0200 Subject: [PATCH] plain/text -> text/plain in comment (#362) --- src/pred.rs | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/pred.rs b/src/pred.rs index 5d47922f..3b7b99c4 100644 --- a/src/pred.rs +++ b/src/pred.rs @@ -68,7 +68,7 @@ impl Predicate for AnyPredicate { /// r.route() /// .filter( /// pred::All(pred::Get()) -/// .and(pred::Header("content-type", "plain/text")), +/// .and(pred::Header("content-type", "text/plain")), /// ) /// .f(|_| HttpResponse::MethodNotAllowed()) /// }); @@ -177,7 +177,8 @@ pub fn Method(method: http::Method) -> MethodPredicate { /// Return predicate that matches if request contains specified header and /// value. pub fn Header( - name: &'static str, value: &'static str, + name: &'static str, + value: &'static str, ) -> HeaderPredicate { HeaderPredicate( header::HeaderName::try_from(name).unwrap(),