1
0
mirror of https://github.com/fafhrd91/actix-web synced 2025-08-28 07:47:49 +02:00

load cookies automatically

This commit is contained in:
Nikolay Kim
2017-12-07 18:00:20 -08:00
parent 0abb3863dc
commit d595dd850e
5 changed files with 38 additions and 52 deletions

View File

@@ -54,7 +54,7 @@ impl<S> Router<S> {
/// Router prefix
#[inline]
pub(crate) fn prefix(&self) -> &str {
pub fn prefix(&self) -> &str {
&self.0.prefix
}
@@ -74,7 +74,6 @@ impl<S> Router<S> {
if let Some(idx) = idx {
let path: &str = unsafe{ mem::transmute(&req.path()[self.0.prefix.len()..]) };
req.set_prefix(self.prefix().len());
self.0.patterns[idx].update_match_info(path, req);
return Some(&self.0.resources[idx])
} else {