@streamflow/staking 7.4.17 → 7.4.18
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/cjs/solana/client.js +0 -14
- package/dist/esm/solana/client.js +1 -15
- package/package.json +4 -4
|
@@ -143,20 +143,6 @@ class SolanaStakingClient {
|
|
|
143
143
|
payer: staker,
|
|
144
144
|
})
|
|
145
145
|
.instruction();
|
|
146
|
-
if (this.cluster == common_1.ICluster.Mainnet) {
|
|
147
|
-
// TODO: remove when staking on mainnet is upgraded
|
|
148
|
-
instruction.keys.pop();
|
|
149
|
-
instruction.keys.push({
|
|
150
|
-
pubkey: web3_js_1.SYSVAR_RENT_PUBKEY,
|
|
151
|
-
isSigner: false,
|
|
152
|
-
isWritable: false,
|
|
153
|
-
});
|
|
154
|
-
instruction.keys.push({
|
|
155
|
-
pubkey: web3_js_1.SystemProgram.programId,
|
|
156
|
-
isSigner: false,
|
|
157
|
-
isWritable: false,
|
|
158
|
-
});
|
|
159
|
-
}
|
|
160
146
|
return { ixs: [instruction] };
|
|
161
147
|
}
|
|
162
148
|
async unstake(data, extParams) {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { Program, parseIdlErrors, translateError, } from "@coral-xyz/anchor";
|
|
2
2
|
import { TOKEN_PROGRAM_ID, getAssociatedTokenAddressSync } from "@solana/spl-token";
|
|
3
|
-
import { Connection, PublicKey
|
|
3
|
+
import { Connection, PublicKey } from "@solana/web3.js";
|
|
4
4
|
import { ContractError, ICluster, invariant } from "@streamflow/common";
|
|
5
5
|
import { buildSendThrottler, checkOrCreateAtaBatch, getFilters, pk, prepareBaseInstructions, prepareTransaction, signAndExecuteTransaction, } from "@streamflow/common/solana";
|
|
6
6
|
import { REWARD_ENTRY_BYTE_OFFSETS, REWARD_POOL_BYTE_OFFSETS, REWARD_POOL_PROGRAM_ID, STAKE_ENTRY_BYTE_OFFSETS, STAKE_POOL_BYTE_OFFSETS, STAKE_POOL_PROGRAM_ID, STREAMFLOW_TREASURY_PUBLIC_KEY, } from "./constants.js";
|
|
@@ -142,20 +142,6 @@ export class SolanaStakingClient {
|
|
|
142
142
|
payer: staker,
|
|
143
143
|
})
|
|
144
144
|
.instruction();
|
|
145
|
-
if (this.cluster == ICluster.Mainnet) {
|
|
146
|
-
// TODO: remove when staking on mainnet is upgraded
|
|
147
|
-
instruction.keys.pop();
|
|
148
|
-
instruction.keys.push({
|
|
149
|
-
pubkey: SYSVAR_RENT_PUBKEY,
|
|
150
|
-
isSigner: false,
|
|
151
|
-
isWritable: false,
|
|
152
|
-
});
|
|
153
|
-
instruction.keys.push({
|
|
154
|
-
pubkey: SystemProgram.programId,
|
|
155
|
-
isSigner: false,
|
|
156
|
-
isWritable: false,
|
|
157
|
-
});
|
|
158
|
-
}
|
|
159
145
|
return { ixs: [instruction] };
|
|
160
146
|
}
|
|
161
147
|
async unstake(data, extParams) {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@streamflow/staking",
|
|
3
|
-
"version": "7.4.
|
|
3
|
+
"version": "7.4.18",
|
|
4
4
|
"description": "JavaScript SDK to interact with Streamflow Staking protocol.",
|
|
5
5
|
"homepage": "https://github.com/streamflow-finance/js-sdk/",
|
|
6
6
|
"main": "dist/esm/index.js",
|
|
@@ -27,9 +27,9 @@
|
|
|
27
27
|
"test": "vitest",
|
|
28
28
|
"prepublishOnly": "pnpm run lint && pnpm run test run && pnpm run build"
|
|
29
29
|
},
|
|
30
|
-
"gitHead": "
|
|
30
|
+
"gitHead": "ea8a4050dcd41647b66985a2ca32cc613483dc5f",
|
|
31
31
|
"devDependencies": {
|
|
32
|
-
"@streamflow/eslint-config": "7.4.
|
|
32
|
+
"@streamflow/eslint-config": "7.4.18",
|
|
33
33
|
"@types/bn.js": "5.1.1",
|
|
34
34
|
"typescript": "^5.6.3"
|
|
35
35
|
},
|
|
@@ -40,7 +40,7 @@
|
|
|
40
40
|
"@solana/spl-token": "0.4.9",
|
|
41
41
|
"@solana/wallet-adapter-base": "0.9.19",
|
|
42
42
|
"@solana/web3.js": "1.95.4",
|
|
43
|
-
"@streamflow/common": "7.4.
|
|
43
|
+
"@streamflow/common": "7.4.18",
|
|
44
44
|
"bn.js": "5.2.1",
|
|
45
45
|
"borsh": "^2.0.0",
|
|
46
46
|
"bs58": "5.0.0",
|