From abf573812ff0c8e33950c41c65bd18a64a67733a Mon Sep 17 00:00:00 2001 From: shockrah Date: Fri, 31 Jan 2020 00:16:22 -0800 Subject: [PATCH] new struct for invites --- server/src/db_io/src/models.rs | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/server/src/db_io/src/models.rs b/server/src/db_io/src/models.rs index 879b84f..a4074aa 100644 --- a/server/src/db_io/src/models.rs +++ b/server/src/db_io/src/models.rs @@ -13,3 +13,10 @@ pub struct channels { pub name: String, pub ctype: i64, } + +#[derive(Queryable)] +pub struct Invite { + pub hash: i64, + pub uses: i32, // simple that tracks the number of uses a thing has left + pub expire: i64, // used as a unix time stamp +}