@yodlpay/payment-decoder 1.3.1 → 1.3.2
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.js +6 -1
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -269,7 +269,12 @@ function areMirrorTransfers(a, b) {
|
|
|
269
269
|
}
|
|
270
270
|
function detectMirrorTokens(allTransfers) {
|
|
271
271
|
const mirrors = /* @__PURE__ */ new Map();
|
|
272
|
-
const byToken =
|
|
272
|
+
const byToken = /* @__PURE__ */ new Map();
|
|
273
|
+
for (const t of allTransfers) {
|
|
274
|
+
const key = getAddress(t.token);
|
|
275
|
+
const group = byToken.get(key);
|
|
276
|
+
group ? group.push(t) : byToken.set(key, [t]);
|
|
277
|
+
}
|
|
273
278
|
const tokens = [...byToken.keys()];
|
|
274
279
|
for (const [i, tokenA] of tokens.entries()) {
|
|
275
280
|
if (mirrors.has(tokenA)) continue;
|