We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent fc8091b commit c00ade0Copy full SHA for c00ade0
modules/abstract-utxo/src/abstractUtxoCoin.ts
@@ -570,7 +570,11 @@ export abstract class AbstractUtxoCoin extends BaseCoin {
570
if (typeof input === 'string') {
571
for (const format of ['hex', 'base64'] as const) {
572
const buffer = Buffer.from(input, format);
573
- if (buffer.toString(format) === input.toLowerCase()) {
+ const bufferToString = buffer.toString(format);
574
+ if (
575
+ (format === 'base64' && bufferToString === input) ||
576
+ (format === 'hex' && bufferToString === input.toLowerCase())
577
+ ) {
578
return this.decodeTransaction(buffer);
579
}
580
0 commit comments