@engage_so/core
Advanced tools
Comparing version 1.5.0 to 1.6.0
12
index.js
@@ -18,6 +18,3 @@ const fetch = require('cross-fetch') | ||
try { | ||
if (!params) { | ||
params = {} | ||
} | ||
const response = await fetch(url, { | ||
const o = { | ||
method, | ||
@@ -28,4 +25,7 @@ headers: { | ||
}, | ||
body: JSON.stringify(params) | ||
}) | ||
} | ||
if (params) { | ||
o.body = JSON.stringify(params) | ||
} | ||
const response = await fetch(url, o) | ||
const body = await response.json() | ||
@@ -32,0 +32,0 @@ let error = 'API connection error' |
{ | ||
"name": "@engage_so/core", | ||
"version": "1.5.0", | ||
"version": "1.6.0", | ||
"description": "Event driven customer segmentation and targeted engagement.", | ||
@@ -21,3 +21,3 @@ "main": "index.js", | ||
}, | ||
"gitHead": "16373af376360be8a4e71aeff74c86648d37072a" | ||
"gitHead": "7db0b36d47cee47daf1bb9412ced6bec0f23462b" | ||
} |
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