@vtecx/vtecxnext 1.1.6 → 1.1.7
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/dist/vtecxnext.js +12 -1
- package/package.json +1 -1
package/dist/vtecxnext.js
CHANGED
|
@@ -3077,7 +3077,18 @@ const requestVtecx = async (method, url, req, body, additionalHeaders, targetSer
|
|
|
3077
3077
|
}
|
|
3078
3078
|
if (targetService) {
|
|
3079
3079
|
// サービス連携の場合
|
|
3080
|
-
|
|
3080
|
+
let servicekey = process.env[`SERVICEKEY_${targetService}`];
|
|
3081
|
+
if (!servicekey) {
|
|
3082
|
+
const max = 10;
|
|
3083
|
+
for (let i = 1; i <= max; i++) {
|
|
3084
|
+
const iStr = String(i);
|
|
3085
|
+
const tmpServiceName = process.env[`SERVICELINKAGE_${iStr}`];
|
|
3086
|
+
if (targetService == tmpServiceName) {
|
|
3087
|
+
servicekey = process.env[`SERVICEKEY_${iStr}`];
|
|
3088
|
+
break;
|
|
3089
|
+
}
|
|
3090
|
+
}
|
|
3091
|
+
}
|
|
3081
3092
|
//console.log(`[requestVtecx] targetService=${targetService} servicekey=${servicekey}`)
|
|
3082
3093
|
if (servicekey) {
|
|
3083
3094
|
headers['X-SERVICELINKAGE'] = targetService;
|