mirror of
https://github.com/monkeytypegame/monkeytype.git
synced 2025-11-09 21:51:29 +08:00
logging version
This commit is contained in:
parent
29cfe8d932
commit
8f0f63182e
2 changed files with 2 additions and 2 deletions
|
|
@ -2,7 +2,7 @@ export function implemented(): boolean {
|
|||
return false;
|
||||
}
|
||||
|
||||
export function validateResult(_result: object): boolean {
|
||||
export function validateResult(_result: object, _version: string): boolean {
|
||||
return true;
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -197,7 +197,7 @@ export async function addResult(
|
|||
}
|
||||
|
||||
if (anticheatImplemented()) {
|
||||
if (!validateResult(result)) {
|
||||
if (!validateResult(result, req.headers["client-version"] as string)) {
|
||||
const status = MonkeyStatusCodes.RESULT_DATA_INVALID;
|
||||
throw new MonkeyError(status.code, "Result data doesn't make sense");
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue