Add a comment to clarify the ban expires field. (#4400)

* Add a comment to clarify the ban expires field.

* Add comment about simpler client implementation.

* Better language.
This commit is contained in:
Dessalines 2024-01-25 10:45:42 -05:00 committed by GitHub
parent dadf8f28f9
commit 8cde452fca
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
2 changed files with 6 additions and 0 deletions

View file

@ -97,6 +97,9 @@ pub struct BanFromCommunity {
pub ban: bool,
pub remove_data: Option<bool>,
pub reason: Option<String>,
/// A time that the ban will expire, in unix epoch seconds.
///
/// An i64 unix timestamp is used for a simpler API client implementation.
pub expires: Option<i64>,
}

View file

@ -214,6 +214,9 @@ pub struct BanPerson {
/// Optionally remove all their data. Useful for new troll accounts.
pub remove_data: Option<bool>,
pub reason: Option<String>,
/// A time that the ban will expire, in unix epoch seconds.
///
/// An i64 unix timestamp is used for a simpler API client implementation.
pub expires: Option<i64>,
}