@ethereansos/interfaces-core 0.4.102 → 0.4.103

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/index.cjs.js CHANGED
@@ -63764,6 +63764,56 @@ const gBase64 = {
63764
63764
  extendBuiltins: extendBuiltins,
63765
63765
  };
63766
63766
 
63767
+ function memoryFetch(_x, _x2) {
63768
+ return _memoryFetch.apply(this, arguments);
63769
+ }
63770
+
63771
+ function _memoryFetch() {
63772
+ _memoryFetch = _asyncToGenerator$1( /*#__PURE__*/regeneratorRuntime.mark(function _callee(url, type) {
63773
+ var element;
63774
+ return regeneratorRuntime.wrap(function _callee$(_context) {
63775
+ while (1) {
63776
+ switch (_context.prev = _context.next) {
63777
+ case 0:
63778
+ try {
63779
+ element = JSON.parse(window.localStorage.getItem(url));
63780
+ } catch (e) {}
63781
+
63782
+ if (!element) {
63783
+ _context.next = 3;
63784
+ break;
63785
+ }
63786
+
63787
+ return _context.abrupt("return", element);
63788
+
63789
+ case 3:
63790
+ _context.next = 5;
63791
+ return fetch(url);
63792
+
63793
+ case 5:
63794
+ element = _context.sent;
63795
+ _context.next = 8;
63796
+ return element[type || 'json']();
63797
+
63798
+ case 8:
63799
+ element = _context.sent;
63800
+
63801
+ try {
63802
+ window.localStorage.setItem(url, JSON.stringify(element));
63803
+ } catch (e) {}
63804
+
63805
+ return _context.abrupt("return", element);
63806
+
63807
+ case 11:
63808
+ case "end":
63809
+ return _context.stop();
63810
+ }
63811
+ }
63812
+ }, _callee);
63813
+ }));
63814
+ return _memoryFetch.apply(this, arguments);
63815
+ }
63816
+
63767
63817
  function cleanLink(linkToClean) {
63768
63818
  var cleanedLink = linkToClean;
63769
63819
 
@@ -63859,7 +63909,7 @@ function _tryRetrieveMetadata() {
63859
63909
 
63860
63910
  case 28:
63861
63911
  _context.next = 30;
63862
- return fetch(cleanLink(formatLink({
63912
+ return memoryFetch(cleanLink(formatLink({
63863
63913
  context: context
63864
63914
  }, item.metadataLink)));
63865
63915
 
@@ -64996,6 +65046,7 @@ exports.loadMetadatas = loadMetadatas;
64996
65046
  exports.loadOffchainWallets = loadOffChainWallets;
64997
65047
  exports.logger = logger;
64998
65048
  exports.maxLiquidityForAmounts = maxLiquidityForAmounts;
65049
+ exports.memoryFetch = memoryFetch;
64999
65050
  exports.methodSignatureMatch = methodSignatureMatch;
65000
65051
  exports.mint = mint;
65001
65052
  exports.mostSignificantBit = mostSignificantBit;