diff options
Diffstat (limited to 'src/app.rs')
| -rw-r--r-- | src/app.rs | 10 |
1 files changed, 8 insertions, 2 deletions
@@ -71,6 +71,10 @@ impl App { pub fn users(&self) -> Users { Users::new(self.db.clone(), self.events.clone()) } + + pub fn vapid(&self) -> Vapid { + Vapid::new(self.db.clone(), self.events.clone()) + } } impl FromRef<App> for Boot { @@ -113,8 +117,10 @@ impl FromRef<App> for Tokens { fn from_ref(app: &App) -> Self { app.tokens() } +} - pub const fn vapid(&self) -> Vapid<'_> { - Vapid::new(&self.db, &self.events) +impl FromRef<App> for Vapid { + fn from_ref(app: &App) -> Self { + app.vapid() } } |
