summaryrefslogtreecommitdiff
path: root/std/node/util.ts
diff options
context:
space:
mode:
authorSchwarzkopf Balázs <schwarzkopfb@icloud.com>2020-08-27 11:00:38 +0200
committerGitHub <noreply@github.com>2020-08-27 11:00:38 +0200
commite1564f385c770ac37c550f7d9e164d6a846c191e (patch)
tree1fbf2e00012793b64f07c8085d6e4d006a139a3b /std/node/util.ts
parent7583fd0979ee35144c7df078d00aa2e78b510be9 (diff)
fix(std/node): "events" and "util" modules (#7170)
Diffstat (limited to 'std/node/util.ts')
-rw-r--r--std/node/util.ts17
1 files changed, 0 insertions, 17 deletions
diff --git a/std/node/util.ts b/std/node/util.ts
index e897931f2..ce1c06b7c 100644
--- a/std/node/util.ts
+++ b/std/node/util.ts
@@ -68,23 +68,6 @@ export function isPrimitive(value: unknown): boolean {
);
}
-export function validateIntegerRange(
- value: number,
- name: string,
- min = -2147483648,
- max = 2147483647,
-): void {
- // The defaults for min and max correspond to the limits of 32-bit integers.
- if (!Number.isInteger(value)) {
- throw new Error(`${name} must be 'an integer' but was ${value}`);
- }
- if (value < min || value > max) {
- throw new Error(
- `${name} must be >= ${min} && <= ${max}. Value was ${value}`,
- );
- }
-}
-
import { _TextDecoder, _TextEncoder } from "./_utils.ts";
/** The global TextDecoder */