Fix NaN comparison

This commit is contained in:
Daniel Imms
2019-10-21 18:44:03 -07:00
parent 631107698e
commit 09b244ed2f
+1 -1
View File
@@ -181,7 +181,7 @@ export class Terminal implements ITerminalApi {
private _verifyIntegers(...values: number[]): void {
values.forEach(value => {
if (value === Infinity || value === NaN || value % 1 !== 0) {
if (value === Infinity || isNaN(value) || value % 1 !== 0) {
throw new Error('This API only accepts integers');
}
});