fix: normalize TOTPKey format and enhance debug messages in RequestHandler

This commit is contained in:
Elysia
2025-07-10 21:11:24 +07:00
parent 780dfe8078
commit 23c669bef9
2 changed files with 7 additions and 2 deletions

View File

@@ -332,7 +332,7 @@ class RequestHandler {
this.manager.client.emit(
DEBUG,
`Hit a 429 while executing a request.
`[Request Handler] Hit a 429 while executing a request.
Global : ${isGlobal}
Method : ${request.method}
Path : ${request.path}
@@ -397,6 +397,7 @@ class RequestHandler {
* ticket: string;
* methods: {
* type: "password" | "totp" | "sms" | "backup" | "webauthn";
* backup_codes_allowed?: boolean;
* }[];
* };
* };
@@ -409,7 +410,7 @@ class RequestHandler {
const otp = this.manager.client.authenticator.generate(this.manager.client.options.TOTPKey);
this.manager.client.emit(
DEBUG,
`${data.message}
`[Request Handler] ${data.message}
Method : ${request.method}
Path : ${request.path}
Route : ${request.route}