feat: login handler

This commit is contained in:
手瓜一十雪 committed 2024-05-06 22:52:57 +08:00
1 parent 54ab1dc091
commit bd8a1d715f
4 files changed
+35 -7

No files matched your search

+1 -1
View File
@@ -2,7 +2,7 @@ let LoginRuntime = {
LoginCurrentTime: Date.now(),
LoginCurrentRate: 0
}
export const Data = {
export const DataRuntime = {
checkLoginRate: async function (RateLimit: number): Promise<boolean> {
if (Date.now() - LoginRuntime.LoginCurrentTime > 1000 * 60) {
LoginRuntime.LoginCurrentRate = 0;//超出时间重置限速