@bsv/sdk 2.0.1 → 2.0.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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@bsv/sdk",
3
- "version": "2.0.1",
3
+ "version": "2.0.2",
4
4
  "type": "module",
5
5
  "description": "BSV Blockchain Software Development Kit",
6
6
  "main": "dist/cjs/mod.js",
@@ -119,13 +119,13 @@ export default class WalletClient implements WalletInterface {
119
119
  }
120
120
  }
121
121
 
122
- // Try fast substrates first
122
+ // Try all substrates concurrently, select first available by priority order
123
123
  const fastAttempts = [
124
124
  attemptSubstrate(() => new WindowCWISubstrate()),
125
+ attemptSubstrate(() => new WalletWireTransceiver(new HTTPWalletWire(this.originator))),
125
126
  attemptSubstrate(() => new HTTPWalletJSON(this.originator, 'https://localhost:2121')),
126
127
  attemptSubstrate(() => new HTTPWalletJSON(this.originator)),
127
- attemptSubstrate(() => new ReactNativeWebView(this.originator)),
128
- attemptSubstrate(() => new WalletWireTransceiver(new HTTPWalletWire(this.originator)))
128
+ attemptSubstrate(() => new ReactNativeWebView(this.originator))
129
129
  ]
130
130
 
131
131
  const fastResults = await Promise.allSettled(fastAttempts)
@@ -1686,7 +1686,7 @@ export default class WalletWireTransceiver implements WalletInterface {
1686
1686
  const fieldKey = Utils.toUTF8(resultReader.read(fieldKeyLength))
1687
1687
  const fieldValueLength = resultReader.readVarIntNum()
1688
1688
  keyringForVerifier[fieldKey] = Utils.toBase64(
1689
- resultReader.read(fieldValueLength)
1689
+ resultReader.read(fieldValueLength)
1690
1690
  )
1691
1691
  }
1692
1692
  }