clearTimeout's params should not be bigint (#2838)

This commit is contained in:
迷渡 2019-08-30 23:51:53 +08:00 committed by Ryan Dahl
parent c370f749b2
commit 65fa2b810b
2 changed files with 17 additions and 0 deletions

View file

@ -262,6 +262,7 @@ function clearTimer(id: number): void {
}
export function clearTimeout(id: number = 0): void {
checkBigInt(id);
if (id === 0) {
return;
}
@ -269,6 +270,7 @@ export function clearTimeout(id: number = 0): void {
}
export function clearInterval(id: number = 0): void {
checkBigInt(id);
if (id === 0) {
return;
}