@pioneer-platform/maya-network 8.13.17 → 8.13.19
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/.turbo/turbo-build.log +1 -2
- package/CHANGELOG.md +12 -0
- package/lib/index.js +7 -0
- package/package.json +1 -1
package/.turbo/turbo-build.log
CHANGED
|
@@ -1,2 +1 @@
|
|
|
1
|
-
|
|
2
|
-
[0m[2m[35m$[0m [2m[1mtsc -p .[0m
|
|
1
|
+
$ tsc -p .
|
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,17 @@
|
|
|
1
1
|
# @pioneer-platform/maya-network
|
|
2
2
|
|
|
3
|
+
## 8.13.19
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- Fix account info selection to prefer sources with more coins (CACAO + MAYA)
|
|
8
|
+
|
|
9
|
+
## 8.13.18
|
|
10
|
+
|
|
11
|
+
### Patch Changes
|
|
12
|
+
|
|
13
|
+
- fix(pioneer-nodes): remove broken node entry without service field
|
|
14
|
+
|
|
3
15
|
## 8.13.17
|
|
4
16
|
|
|
5
17
|
### Patch Changes
|
package/lib/index.js
CHANGED
|
@@ -283,6 +283,13 @@ var get_account_info = function (address) {
|
|
|
283
283
|
return current;
|
|
284
284
|
if (bestAcctNum > 0 && currentAcctNum === 0)
|
|
285
285
|
return best;
|
|
286
|
+
// CRITICAL: Prefer sources with MORE coins (to get both CACAO + MAYA)
|
|
287
|
+
var currentCoinCount = current.coins.length;
|
|
288
|
+
var bestCoinCount = best.coins.length;
|
|
289
|
+
if (currentCoinCount > bestCoinCount)
|
|
290
|
+
return current;
|
|
291
|
+
if (bestCoinCount > currentCoinCount)
|
|
292
|
+
return best;
|
|
286
293
|
// Check for balance (coins array)
|
|
287
294
|
var currentHasBalance = current.coins.length > 0;
|
|
288
295
|
var bestHasBalance = best.coins.length > 0;
|