From dcb561584d73868f0c283584b5cb52864e4b883e Mon Sep 17 00:00:00 2001 From: Nikolay Kim Date: Sat, 2 Jun 2018 11:55:27 -0700 Subject: [PATCH 1/2] remove debug print --- src/httprequest.rs | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/src/httprequest.rs b/src/httprequest.rs index a618abdcc..1d9f6245f 100644 --- a/src/httprequest.rs +++ b/src/httprequest.rs @@ -283,9 +283,9 @@ impl HttpRequest { /// Generate url for named resource /// /// ```rust - /// # extern crate actix_web; - /// # use actix_web::{App, HttpRequest, HttpResponse, http}; - /// # + /// //#### # extern crate actix_web; + /// //#### # use actix_web::{App, HttpRequest, HttpResponse, http}; + /// //#### # /// fn index(req: HttpRequest) -> HttpResponse { /// let url = req.url_for("foo", &["1", "2", "3"]); // <- generate url for "foo" resource /// HttpResponse::Ok().into() @@ -311,7 +311,6 @@ impl HttpRequest { Err(UrlGenerationError::RouterNotAvailable) } else { let path = self.router().unwrap().resource_path(name, elements)?; - println!("==== {:?}", path); if path.starts_with('/') { let conn = self.connection_info(); Ok(Url::parse(&format!( From 3c472a2f66881cc213e6b12e1e70f8e309c2b8ec Mon Sep 17 00:00:00 2001 From: Nikolay Kim Date: Sat, 2 Jun 2018 11:57:49 -0700 Subject: [PATCH 2/2] remove debug prints --- src/router.rs | 3 --- 1 file changed, 3 deletions(-) diff --git a/src/router.rs b/src/router.rs index c2ce4f546..c9ff9d705 100644 --- a/src/router.rs +++ b/src/router.rs @@ -211,8 +211,6 @@ impl Resource { let (pattern, elements, is_dynamic, len) = Resource::parse(path, prefix, for_prefix); - println!("ELEMENT: {:?} {:?} {:?}", pattern, elements, is_dynamic); - let tp = if is_dynamic { let re = match Regex::new(&pattern) { Ok(re) => re, @@ -347,7 +345,6 @@ impl Resource { let mut path = String::new(); let mut iter = elements.into_iter(); for el in &self.elements { - println!("EL: {:?}", el); match *el { PatternElement::Str(ref s) => path.push_str(s), PatternElement::Var(_) => {