style: renaming parameter, ban_time -> banned_since
All checks were successful
ci/woodpecker/push/build-and-publish Pipeline was successful
ci/woodpecker/pr/build-and-publish Pipeline was successful

This commit is contained in:
BAaboe 2025-07-24 01:58:10 +02:00
parent 26f528819e
commit c2b5f6568f
3 changed files with 3 additions and 3 deletions

View file

@ -3,6 +3,6 @@ CREATE TABLE guild_bans (
guild_uuid uuid NOT NULL REFERENCES guilds(uuid) ON DELETE CASCADE, guild_uuid uuid NOT NULL REFERENCES guilds(uuid) ON DELETE CASCADE,
user_uuid uuid NOT NULL REFERENCES users(uuid), user_uuid uuid NOT NULL REFERENCES users(uuid),
reason VARCHAR(200) DEFAULT NULL, 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) PRIMARY KEY (user_uuid, guild_uuid)
); );

View file

@ -13,7 +13,7 @@ pub struct GuildBan {
pub guild_uuid: Uuid, pub guild_uuid: Uuid,
pub user_uuid: Uuid, pub user_uuid: Uuid,
pub reason: Option<String>, pub reason: Option<String>,
pub ban_time: chrono::DateTime<chrono::Utc>, pub banned_since: chrono::DateTime<chrono::Utc>,
} }
impl GuildBan { impl GuildBan {

View file

@ -53,7 +53,7 @@ diesel::table! {
user_uuid -> Uuid, user_uuid -> Uuid,
#[max_length = 200] #[max_length = 200]
reason -> Nullable<Varchar>, reason -> Nullable<Varchar>,
ban_time -> Timestamptz, banned_since -> Timestamptz,
} }
} }