Limit 'superuser' status of current moderators (#386)

Resolves MOD-88

Co-authored-by: Geometrically <18202329+Geometrically@users.noreply.github.com>
This commit is contained in:
wafflecoffeeandGeometrically authored and GitHub committed 2022-07-23 18:47:32 -07:00
1 parent 6614b56298
commit b864791fa6
9 files changed
+32 -19

No files matched your search

+7
View File
@@ -77,4 +77,11 @@ impl Role {
Role::Moderator | Role::Admin => true,
}
}
pub fn is_admin(&self) -> bool {
match self {
Role::Developer | Role::Moderator => false,
Role::Admin => true,
}
}
}