@alicloud/tea-util
Advanced tools
Comparing version 1.4.1 to 1.4.2
@@ -61,2 +61,3 @@ /// <reference types="node" /> | ||
}; | ||
static assertAsArray(value: any): any[]; | ||
static assertAsBytes(value: any): Buffer; | ||
@@ -63,0 +64,0 @@ static getUserAgent(userAgent: string): string; |
@@ -179,2 +179,8 @@ "use strict"; | ||
} | ||
static assertAsArray(value) { | ||
if (Array.isArray(value)) { | ||
return value; | ||
} | ||
throw new Error(`The value is not array`); | ||
} | ||
static assertAsBytes(value) { | ||
@@ -181,0 +187,0 @@ if (Buffer.isBuffer(value)) { |
{ | ||
"name": "@alicloud/tea-util", | ||
"version": "1.4.1", | ||
"version": "1.4.2", | ||
"description": "", | ||
@@ -5,0 +5,0 @@ "main": "dist/client.js", |
@@ -214,2 +214,9 @@ import { Readable } from 'stream'; | ||
static assertAsArray(value: any): any[] { | ||
if (Array.isArray(value)) { | ||
return value; | ||
} | ||
throw new Error(`The value is not array`); | ||
} | ||
static assertAsBytes(value: any): Buffer { | ||
@@ -216,0 +223,0 @@ if (Buffer.isBuffer(value)) { |
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
23403
544