From 139fa3b9a26d254863723130f7b6c15cc2de96d1 Mon Sep 17 00:00:00 2001 From: Pirmin Kalberer Date: Wed, 15 May 2019 20:51:24 +0200 Subject: [PATCH] Fix typo --- router/src/router.rs | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/router/src/router.rs b/router/src/router.rs index 0faa27be..bffc208f 100644 --- a/router/src/router.rs +++ b/router/src/router.rs @@ -19,26 +19,26 @@ impl Router { } } - pub fn recognize(&self, reosurce: &mut R) -> Option<(&T, ResourceId)> + pub fn recognize(&self, resource: &mut R) -> Option<(&T, ResourceId)> where R: Resource

, P: ResourcePath, { for item in self.0.iter() { - if item.0.match_path(reosurce.resource_path()) { + if item.0.match_path(resource.resource_path()) { return Some((&item.1, ResourceId(item.0.id()))); } } None } - pub fn recognize_mut(&mut self, reosurce: &mut R) -> Option<(&mut T, ResourceId)> + pub fn recognize_mut(&mut self, resource: &mut R) -> Option<(&mut T, ResourceId)> where R: Resource

, P: ResourcePath, { for item in self.0.iter_mut() { - if item.0.match_path(reosurce.resource_path()) { + if item.0.match_path(resource.resource_path()) { return Some((&mut item.1, ResourceId(item.0.id()))); } }