Skip to content

Commit 42f7e99

Browse files
committed
fix type
1 parent d985b91 commit 42f7e99

1 file changed

Lines changed: 3 additions & 1 deletion

File tree

svc/retriever.ts

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -193,8 +193,10 @@ const server = createServer(async (req, res) => {
193193
// Community prediction match or other reason valve is blocking
194194
const isBlockedByValve = matchData.result === 15;
195195
const isExtremelyOldMatch =
196-
matchData.match?.game_mode === "DOTA_GAMEMODE_NONE" &&
196+
// DOTA_GAMEMODE_NONE, the original response is a number even though the returned response is a string after JSON.stringify()
197+
matchData.match?.game_mode === 0 &&
197198
matchData.match?.replay_salt === 0;
199+
console.log(matchData.match?.game_mode, matchData.match?.replay_salt, isExtremelyOldMatch);
198200
const isMatchNotFound = matchData.result === 2;
199201
if (isBlockedByValve || isExtremelyOldMatch || isMatchNotFound) {
200202
let reason = "";

0 commit comments

Comments
 (0)