@quantovainc/qcore 0.1.13 → 0.1.15

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": "@quantovainc/qcore",
3
- "version": "0.1.13",
3
+ "version": "0.1.15",
4
4
  "description": "Quantova's post quantum client core for JavaScript. Signs with ML-DSA-65 and builds Q1 addresses.",
5
5
  "scripts": {
6
6
  "build": "wasm-pack build --target bundler --out-dir pkg && wasm-pack build --target nodejs --out-dir pkg-node",
Binary file
Binary file
package/shared.js CHANGED
@@ -183,6 +183,8 @@ function makeClient(core) {
183
183
  const configured = this.network && this.network.chainId;
184
184
  if (configured && name !== configured) {
185
185
  throw new Error(`the gateway reports chain ${name} but this client is configured for ${configured}; refusing to sign a transaction that would be valid on a network you did not choose`);
186
+ } else if (!configured && name === 'Q-main-net-1' && !this.acknowledgeMainnet) {
187
+ throw new Error(`the gateway reports the mainnet chain ${name} but this client did not choose a network; refusing to sign a mainnet transaction without acknowledgeMainnet`);
186
188
  }
187
189
  return BigInt(core.chainIdFromName(name));
188
190
  }