|
|
@@ -314,14 +314,14 @@ class BankClient {
|
|
|
}
|
|
|
getContentItemByHash(hash) {
|
|
|
return __awaiter(this, void 0, void 0, function* () {
|
|
|
- if (!hash.startsWith('/ipfs/')) {
|
|
|
- hash = '/ipfs/' + hash;
|
|
|
+ if (hash.startsWith('/ipfs/')) {
|
|
|
+ hash = hash.split('/').pop();
|
|
|
}
|
|
|
const contentParams = (yield this.webClient.requestJSON({
|
|
|
method: 'get',
|
|
|
- url: this.ipfsUrlBase + hash + '/content.json'
|
|
|
+ url: this.ipfsUrlBase + '/ipfs/' + hash + '/content.json'
|
|
|
}));
|
|
|
- return new content_item_1.ContentItem(contentParams);
|
|
|
+ return new content_item_1.ContentItem(hash, contentParams);
|
|
|
});
|
|
|
}
|
|
|
getItemsForCommaList(commaList) {
|