@pioneer-platform/pioneer-sdk 8.1.45 → 8.1.46

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.
Files changed (2) hide show
  1. package/lib/index.js +12 -10
  2. package/package.json +1 -1
package/lib/index.js CHANGED
@@ -124,16 +124,18 @@ var SDK = /** @class */ (function () {
124
124
  if (userInfo.walletDescriptions) {
125
125
  for (i = 0; userInfo.walletDescriptions.length; i++) {
126
126
  walletInfo = userInfo.walletDescriptions[i];
127
- for (j = 0; j < walletInfo.pubkeys.length; j++) {
128
- pubkey = walletInfo.pubkeys[j];
129
- pubkey.context = walletInfo.context;
130
- this.pubkeys.push(pubkey);
131
- for (k = 0; k < pubkey.balances.length; k++) {
132
- balance = pubkey.balances[k];
133
- //add wallet context
134
- balance.context = walletInfo.context;
135
- balance.pubkey = pubkey.pubkey;
136
- this.balances.push(balance);
127
+ if (walletInfo && walletInfo.pubkeys) {
128
+ for (j = 0; j < walletInfo.pubkeys.length; j++) {
129
+ pubkey = walletInfo.pubkeys[j];
130
+ pubkey.context = walletInfo.context;
131
+ this.pubkeys.push(pubkey);
132
+ for (k = 0; k < pubkey.balances.length; k++) {
133
+ balance = pubkey.balances[k];
134
+ //add wallet context
135
+ balance.context = walletInfo.context;
136
+ balance.pubkey = pubkey.pubkey;
137
+ this.balances.push(balance);
138
+ }
137
139
  }
138
140
  }
139
141
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@pioneer-platform/pioneer-sdk",
3
- "version": "8.1.45",
3
+ "version": "8.1.46",
4
4
  "main": "./lib/index.js",
5
5
  "types": "./lib/index.d.ts",
6
6
  "scripts": {