@slavmak2486/bx24ts 1.1.1 → 1.1.3
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/base/BX24.ts +3 -8
- package/dist/base/BX24.js +3 -9
- package/package.json +1 -1
package/base/BX24.ts
CHANGED
|
@@ -299,14 +299,9 @@ export abstract class baseBX24{
|
|
|
299
299
|
let cnt=0;
|
|
300
300
|
|
|
301
301
|
for(const idx in cmd){
|
|
302
|
-
|
|
303
|
-
|
|
304
|
-
|
|
305
|
-
}
|
|
306
|
-
else if (__get(cmd[idx], 'method', undefined)!=undefined)
|
|
307
|
-
{
|
|
308
|
-
method = __get(cmd[idx], 'method', undefined); params = __get(cmd[idx], 'params', {});
|
|
309
|
-
}
|
|
302
|
+
const row=cmd[idx];
|
|
303
|
+
const method=Array.isArray(row)?row[0]:row.method;
|
|
304
|
+
const params=Array.isArray(row)?row[1]:row.params;
|
|
310
305
|
|
|
311
306
|
if(method)
|
|
312
307
|
{
|
package/dist/base/BX24.js
CHANGED
|
@@ -247,15 +247,9 @@ class baseBX24 {
|
|
|
247
247
|
const comands = {};
|
|
248
248
|
let cnt = 0;
|
|
249
249
|
for (const idx in cmd) {
|
|
250
|
-
|
|
251
|
-
|
|
252
|
-
|
|
253
|
-
params = (0, lodash_1.get)(cmd[idx], 1, {});
|
|
254
|
-
}
|
|
255
|
-
else if ((0, lodash_1.get)(cmd[idx], 'method', undefined) != undefined) {
|
|
256
|
-
method = (0, lodash_1.get)(cmd[idx], 'method', undefined);
|
|
257
|
-
params = (0, lodash_1.get)(cmd[idx], 'params', {});
|
|
258
|
-
}
|
|
250
|
+
const row = cmd[idx];
|
|
251
|
+
const method = Array.isArray(row) ? row[0] : row.method;
|
|
252
|
+
const params = Array.isArray(row) ? row[1] : row.params;
|
|
259
253
|
if (method) {
|
|
260
254
|
cnt++;
|
|
261
255
|
comands[idx] = `${method}?${encodeURIComponent(this.getHttpString(params))}`;
|