mirror of
https://git.ngram.ca/OpenJam/rc-servers
synced 2026-08-23 23:08:52 +00:00
Also respond with banned error code on first request to web services server
This commit is contained in:
@@ -572,6 +572,10 @@ impl <C: Clone> super::User<C> for UserData {
|
||||
self.perms.developer
|
||||
}
|
||||
|
||||
fn is_banned(&self) -> bool {
|
||||
self.perms.banned
|
||||
}
|
||||
|
||||
async fn unlocked_parts(&self) -> Vec<u32> {
|
||||
match self.db.user_aux_by_user_id_and_descriptor(self.account.id, oj_rc_database::schema::user_aux::Descriptor::UnlockedParts).await {
|
||||
Ok(Some(parts)) => {
|
||||
|
||||
@@ -66,6 +66,7 @@ pub trait User<C>: ChatUser + LobbyUser + MultiplayerUser {
|
||||
fn is_mod(&self) -> bool;
|
||||
fn is_admin(&self) -> bool;
|
||||
fn is_dev(&self) -> bool;
|
||||
fn is_banned(&self) -> bool;
|
||||
async fn unlocked_parts(&self) -> Vec<u32>;
|
||||
async fn selected_garage(&self) -> (String, u32);
|
||||
async fn select_garage(&self, slot: i32) -> Result<(), i16>;
|
||||
|
||||
Reference in New Issue
Block a user