Index: src/json.js |
diff --git a/src/json.js b/src/json.js |
index 8fe30efafc64c9e348267d95c8cfac14aa52027d..6f8489088b5191a2cef1312a10f48121028b6ef7 100644 |
--- a/src/json.js |
+++ b/src/json.js |
@@ -217,7 +217,7 @@ function JSONStringify(value, replacer, space) { |
} |
var gap; |
if (IS_NUMBER(space)) { |
- space = MathMax(0, MathMin($toInteger(space), 10)); |
+ space = MathMax(0, MathMin(TO_INTEGER(space), 10)); |
gap = %_SubString(" ", 0, space); |
} else if (IS_STRING(space)) { |
if (space.length > 10) { |