fix(server): remove all avatarType references after DB column drop

This commit is contained in:
Kirill
2026-05-22 11:36:11 +05:00
parent c3e4f5bdd2
commit bb7b40ac45
7 changed files with 2117 additions and 20 deletions
+7
View File
@@ -3,6 +3,13 @@ const windows = new Map()
const MAX_ATTEMPTS = 5
const WINDOW_MS = 60_000
setInterval(() => {
const now = Date.now()
for (const [ip, entry] of windows) {
if (now - entry.start > WINDOW_MS) windows.delete(ip)
}
}, 5 * 60_000).unref()
export function checkLoginRateLimit(ip) {
const now = Date.now()
const entry = windows.get(ip)