use where clause for long lines

Signed-off-by: Jason Volk <jason@zemos.net>
This commit is contained in:
Jason Volk 2024-08-04 06:32:19 +00:00
parent 4432c06c86
commit eb6e509ad8
2 changed files with 20 additions and 5 deletions

View file

@ -193,11 +193,17 @@ impl Services {
}
}
pub fn try_get<'a, 'b, T: Send + Sync + 'a + 'b + 'static>(&'b self, name: &'a str) -> Result<Arc<T>> {
pub fn try_get<'a, 'b, T>(&'b self, name: &'a str) -> Result<Arc<T>>
where
T: Send + Sync + 'a + 'b + 'static,
{
service::try_get::<T>(&self.service, name)
}
pub fn get<'a, 'b, T: Send + Sync + 'a + 'b + 'static>(&'b self, name: &'a str) -> Option<Arc<T>> {
pub fn get<'a, 'b, T>(&'b self, name: &'a str) -> Option<Arc<T>>
where
T: Send + Sync + 'a + 'b + 'static,
{
service::get::<T>(&self.service, name)
}
}