bi-service-sdk
Advanced tools
Comparing version 1.1.0-alpha to 1.1.0
@@ -38,7 +38,7 @@ #!/usr/bin/env node | ||
//for each app - build sdk npm package with http API versions bundled in | ||
//for each app - build sdk npm package with API versions bundled in | ||
//separate files | ||
Object.keys(specs).forEach(function(appName) { | ||
var files = []; | ||
var tmplType = 'http'; | ||
var tmplType = null; | ||
var subdir = `${tmpDir.name}/${package.name}-${appName}-${package.version}`; | ||
@@ -51,9 +51,20 @@ var buildedPackage = { | ||
if (specs[appName].schemes instanceof Array | ||
&& ~spec[appName].schemes.indexOf('amqp') | ||
&& ~spec[appName].schemes.indexOf('amqps') | ||
) { | ||
tmplType = 'amqp'; | ||
let _spec = _.values(specs[appName]).shift(); | ||
if (_spec && _spec.schemes instanceof Array) { | ||
if ( ~_spec.schemes.indexOf('amqp') | ||
|| ~_spec.schemes.indexOf('amqps') | ||
) { | ||
tmplType = 'amqp'; | ||
} else if ( ~_spec.schemes.indexOf('http') | ||
|| ~_spec.schemes.indexOf('https') | ||
) { | ||
tmplType = 'http'; | ||
} | ||
} | ||
//unsupported API specification | ||
if (!tmplType) { | ||
return; | ||
} | ||
packages.push(buildedPackage); | ||
@@ -60,0 +71,0 @@ fs.mkdirSync(subdir); |
@@ -7,2 +7,7 @@ # Change Log | ||
## 1.1.0 | ||
* [FIXED] - we shouldn't try to build a sdk for unsupported API specification (determined via API protocol) | ||
* [FIXED] - AMQP client sdk was failing to build due to multiple semantic errors | ||
## 1.1.0-alpha | ||
@@ -9,0 +14,0 @@ |
{ | ||
"name": "bi-service-sdk", | ||
"version": "1.1.0-alpha", | ||
"version": "1.1.0", | ||
"description": "Exposes common sdk interface & provides client sdk generator for bi-service based apps", | ||
@@ -5,0 +5,0 @@ "main": "index.js", |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
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
No v1
QualityPackage is not semver >=1. This means it is not stable and does not support ^ ranges.
Found 1 instance in 1 package
112356
1326
1