exempts 'special' user role from auto-ban

This commit is contained in:
nai-degen 2023-05-14 14:37:50 -05:00
parent 6eb121ac66
commit 9ff7381f31
1 changed files with 1 additions and 1 deletions

View File

@ -136,7 +136,7 @@ export function authenticate(token: string, ip: string) {
if (!user.ip.includes(ip)) user.ip.push(ip);
// If too many IPs are associated with the user, disable the account.
if (user.ip.length > MAX_IPS_PER_USER) {
if (user.ip.length > MAX_IPS_PER_USER && user.type !== "special") {
disableUser(token, "Too many IP addresses associated with this token.");
return;
}