@jpool/bond-sdk 0.11.0-next.18 → 0.11.0-next.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/dist/index.js +7 -2
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +7 -4
- package/dist/index.mjs.map +1 -1
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -4574,7 +4574,8 @@ var VALIDATOR_BOND_SEED = "validator_bond";
|
|
|
4574
4574
|
var STANDARD_BOND_SEED = "standard";
|
|
4575
4575
|
var CROWDFUNDING_BOND_SEED = "crowdfunding";
|
|
4576
4576
|
var ENV_PROGRAM_ID = {
|
|
4577
|
-
|
|
4577
|
+
["dev" /* DEV */]: new web3_js.PublicKey("Fo17edWRJewZNTRibgx9iTfjywCW6dzS81VwBLmPFVq1"),
|
|
4578
|
+
["prod" /* PROD */]: new web3_js.PublicKey("BondQ7KqZreTcW2UbeTNDcLCJQ3aXAtLn2Fm6ftaJDU")
|
|
4578
4579
|
};
|
|
4579
4580
|
|
|
4580
4581
|
// src/history.ts
|
|
@@ -6745,7 +6746,11 @@ var JBondClient = class _JBondClient {
|
|
|
6745
6746
|
* Set the environment.
|
|
6746
6747
|
*/
|
|
6747
6748
|
env(env) {
|
|
6748
|
-
|
|
6749
|
+
const envProgramId = ENV_PROGRAM_ID[env];
|
|
6750
|
+
if (!envProgramId) {
|
|
6751
|
+
throw new Error(`Invalid environment: ${env}`);
|
|
6752
|
+
}
|
|
6753
|
+
return this.configure("programId", envProgramId);
|
|
6749
6754
|
}
|
|
6750
6755
|
/**
|
|
6751
6756
|
* Configure a specific option.
|