chargebee 3.11.0 → 3.12.0-beta.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +7 -0
- package/cjs/environment.js +1 -1
- package/cjs/util.js +5 -14
- package/esm/environment.js +1 -1
- package/esm/util.js +5 -14
- package/package.json +5 -1
package/CHANGELOG.md
CHANGED
package/cjs/environment.js
CHANGED
|
@@ -11,7 +11,7 @@ exports.Environment = {
|
|
|
11
11
|
hostSuffix: '.chargebee.com',
|
|
12
12
|
apiPath: '/api/v2',
|
|
13
13
|
timeout: DEFAULT_TIME_OUT,
|
|
14
|
-
clientVersion: 'v3.
|
|
14
|
+
clientVersion: 'v3.12.0-beta.1',
|
|
15
15
|
port: DEFAULT_PORT,
|
|
16
16
|
timemachineWaitInMillis: DEFAULT_TIME_MACHINE_WAIT,
|
|
17
17
|
exportWaitInMillis: DEFAULT_EXPORT_WAIT,
|
package/cjs/util.js
CHANGED
|
@@ -230,19 +230,10 @@ function log(env, { level = 'INFO', message = '', context = {}, functionName = '
|
|
|
230
230
|
const logLine = `[${timestamp}] [${level.toUpperCase()}] [${service}] ${functionName} - ${message}${metaString ? ` (${metaString})` : ''}`;
|
|
231
231
|
console.debug(logLine);
|
|
232
232
|
}
|
|
233
|
-
const crypto_1 = require("crypto");
|
|
234
233
|
function generateUUIDv4() {
|
|
235
|
-
|
|
236
|
-
|
|
237
|
-
|
|
238
|
-
|
|
239
|
-
|
|
240
|
-
const hex = bytes.toString('hex');
|
|
241
|
-
return [
|
|
242
|
-
hex.slice(0, 8),
|
|
243
|
-
hex.slice(8, 12),
|
|
244
|
-
hex.slice(12, 16),
|
|
245
|
-
hex.slice(16, 20),
|
|
246
|
-
hex.slice(20),
|
|
247
|
-
].join('-');
|
|
234
|
+
return 'xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx'.replace(/[xy]/g, (c) => {
|
|
235
|
+
const r = (Math.random() * 16) | 0;
|
|
236
|
+
const v = c === 'x' ? r : (r & 0x3) | 0x8;
|
|
237
|
+
return v.toString(16);
|
|
238
|
+
});
|
|
248
239
|
}
|
package/esm/environment.js
CHANGED
|
@@ -8,7 +8,7 @@ export const Environment = {
|
|
|
8
8
|
hostSuffix: '.chargebee.com',
|
|
9
9
|
apiPath: '/api/v2',
|
|
10
10
|
timeout: DEFAULT_TIME_OUT,
|
|
11
|
-
clientVersion: 'v3.
|
|
11
|
+
clientVersion: 'v3.12.0-beta.1',
|
|
12
12
|
port: DEFAULT_PORT,
|
|
13
13
|
timemachineWaitInMillis: DEFAULT_TIME_MACHINE_WAIT,
|
|
14
14
|
exportWaitInMillis: DEFAULT_EXPORT_WAIT,
|
package/esm/util.js
CHANGED
|
@@ -212,19 +212,10 @@ export function log(env, { level = 'INFO', message = '', context = {}, functionN
|
|
|
212
212
|
const logLine = `[${timestamp}] [${level.toUpperCase()}] [${service}] ${functionName} - ${message}${metaString ? ` (${metaString})` : ''}`;
|
|
213
213
|
console.debug(logLine);
|
|
214
214
|
}
|
|
215
|
-
import { randomBytes } from 'crypto';
|
|
216
215
|
export function generateUUIDv4() {
|
|
217
|
-
|
|
218
|
-
|
|
219
|
-
|
|
220
|
-
|
|
221
|
-
|
|
222
|
-
const hex = bytes.toString('hex');
|
|
223
|
-
return [
|
|
224
|
-
hex.slice(0, 8),
|
|
225
|
-
hex.slice(8, 12),
|
|
226
|
-
hex.slice(12, 16),
|
|
227
|
-
hex.slice(16, 20),
|
|
228
|
-
hex.slice(20),
|
|
229
|
-
].join('-');
|
|
216
|
+
return 'xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx'.replace(/[xy]/g, (c) => {
|
|
217
|
+
const r = (Math.random() * 16) | 0;
|
|
218
|
+
const v = c === 'x' ? r : (r & 0x3) | 0x8;
|
|
219
|
+
return v.toString(16);
|
|
220
|
+
});
|
|
230
221
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "chargebee",
|
|
3
|
-
"version": "3.
|
|
3
|
+
"version": "3.12.0-beta.1",
|
|
4
4
|
"description": "A library for integrating with Chargebee.",
|
|
5
5
|
"scripts": {
|
|
6
6
|
"prepack": "npm install && npm run build",
|
|
@@ -36,6 +36,10 @@
|
|
|
36
36
|
},
|
|
37
37
|
"exports": {
|
|
38
38
|
"types": "./types/index.d.ts",
|
|
39
|
+
"browser": {
|
|
40
|
+
"import": "./esm/chargebee.esm.worker.js",
|
|
41
|
+
"require": "./cjs/chargebee.cjs.worker.js"
|
|
42
|
+
},
|
|
39
43
|
"worker": {
|
|
40
44
|
"import": "./esm/chargebee.esm.worker.js",
|
|
41
45
|
"require": "./cjs/chargebee.cjs.worker.js"
|