diff --git a/migrations/2025-07-22-195121_add_ban/up.sql b/migrations/2025-07-22-195121_add_ban/up.sql index d8d7fab..a590142 100644 --- a/migrations/2025-07-22-195121_add_ban/up.sql +++ b/migrations/2025-07-22-195121_add_ban/up.sql @@ -3,6 +3,6 @@ CREATE TABLE guild_bans ( guild_uuid uuid NOT NULL REFERENCES guilds(uuid) ON DELETE CASCADE, user_uuid uuid NOT NULL REFERENCES users(uuid), reason VARCHAR(200) DEFAULT NULL, - ban_time TIMESTAMPTZ NOT NULL DEFAULT NOW(), + banned_since TIMESTAMPTZ NOT NULL DEFAULT NOW(), PRIMARY KEY (user_uuid, guild_uuid) ); diff --git a/src/objects/bans.rs b/src/objects/bans.rs index 9eb58f5..602afa6 100644 --- a/src/objects/bans.rs +++ b/src/objects/bans.rs @@ -13,7 +13,7 @@ pub struct GuildBan { pub guild_uuid: Uuid, pub user_uuid: Uuid, pub reason: Option, - pub ban_time: chrono::DateTime, + pub banned_since: chrono::DateTime, } impl GuildBan { diff --git a/src/schema.rs b/src/schema.rs index e4d6730..422c3a3 100644 --- a/src/schema.rs +++ b/src/schema.rs @@ -53,7 +53,7 @@ diesel::table! { user_uuid -> Uuid, #[max_length = 200] reason -> Nullable, - ban_time -> Timestamptz, + banned_since -> Timestamptz, } }