@eclesia/indexer-engine 2.5.7 → 2.5.9
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/indexer/index.js +11 -11
- package/dist/utils/text.d.ts +1 -1
- package/dist/utils/text.d.ts.map +1 -1
- package/dist/utils/text.js +5 -2
- package/package.json +1 -1
package/dist/indexer/index.js
CHANGED
|
@@ -458,21 +458,21 @@ class EcleciaIndexer extends emitter_1.EclesiaEmitter {
|
|
|
458
458
|
}
|
|
459
459
|
}
|
|
460
460
|
async callABCI(path, data, height, adHoc = true) {
|
|
461
|
-
|
|
462
|
-
|
|
463
|
-
});
|
|
464
|
-
const abciq = await Promise.race([
|
|
465
|
-
(adHoc ? this.client : this.blockClient).abciQuery({
|
|
461
|
+
try {
|
|
462
|
+
const abciq = await (adHoc ? this.client : this.blockClient).abciQuery({
|
|
466
463
|
path,
|
|
467
464
|
data,
|
|
468
465
|
height: height
|
|
469
|
-
})
|
|
470
|
-
|
|
471
|
-
|
|
472
|
-
|
|
473
|
-
|
|
466
|
+
});
|
|
467
|
+
if (abciq) {
|
|
468
|
+
return abciq.value;
|
|
469
|
+
}
|
|
470
|
+
else {
|
|
471
|
+
this.setStatus("FAILED");
|
|
472
|
+
throw new Error("RPC not responding. Query at: " + path);
|
|
473
|
+
}
|
|
474
474
|
}
|
|
475
|
-
|
|
475
|
+
catch (_e) {
|
|
476
476
|
this.setStatus("FAILED");
|
|
477
477
|
throw new Error("RPC not responding. Query at: " + path);
|
|
478
478
|
}
|
package/dist/utils/text.d.ts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export declare const decodeAttr: (x: Uint8Array | string) => string
|
|
1
|
+
export declare const decodeAttr: (x: Uint8Array | string) => string;
|
|
2
2
|
//# sourceMappingURL=text.d.ts.map
|
package/dist/utils/text.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"text.d.ts","sourceRoot":"","sources":["../../src/utils/text.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,UAAU,GAAI,GAAG,UAAU,GAAG,MAAM,
|
|
1
|
+
{"version":3,"file":"text.d.ts","sourceRoot":"","sources":["../../src/utils/text.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,UAAU,GAAI,GAAG,UAAU,GAAG,MAAM,WAQhD,CAAC"}
|
package/dist/utils/text.js
CHANGED
|
@@ -5,8 +5,11 @@ const decodeAttr = (x) => {
|
|
|
5
5
|
if (typeof x === "string") {
|
|
6
6
|
return x;
|
|
7
7
|
}
|
|
8
|
-
if (x instanceof Uint8Array) {
|
|
9
|
-
return Buffer.from(x).toString()
|
|
8
|
+
else if (x instanceof Uint8Array) {
|
|
9
|
+
return Buffer.from(x).toString();
|
|
10
|
+
}
|
|
11
|
+
else {
|
|
12
|
+
return "";
|
|
10
13
|
}
|
|
11
14
|
};
|
|
12
15
|
exports.decodeAttr = decodeAttr;
|