Merge branch 'master' into admin-disable-user

This commit is contained in:
Daniel García authored and GitHub committed 2020-12-08 15:42:37 +01:00
commit b32f4451ee
14 files changed
+263 -261

No files matched your search

+7
View File
@@ -290,6 +290,13 @@ impl User {
users::table.load::<UserDb>(conn).expect("Error loading users").from_db()
}}
}
pub fn last_active(&self, conn: &DbConn) -> Option<NaiveDateTime> {
match Device::find_latest_active_by_user(&self.uuid, conn) {
Some(device) => Some(device.updated_at),
None => None
}
}
}
impl Invitation {