@clonegod/ttd-sol-common 1.0.182 → 1.0.184

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.
@@ -2,5 +2,4 @@ import { Keypair } from "@solana/web3.js";
2
2
  import { Transaction, TransactionInstruction } from "@solana/web3.js";
3
3
  import { PublicKey } from "@solana/web3.js";
4
4
  export declare function createJitoDontFrontTransaction(recentBlockhash: string, tipPayer: Keypair): Transaction;
5
- export declare function createCustomComputeBudgetInstruction(payerPubkey: any, jitodontfrontPubkey: any, units: any): TransactionInstruction;
6
5
  export declare function createCustomComputeBudgetInstructionWithJitoDontFront(jitodontfrontPubkey: PublicKey, units: number): TransactionInstruction;
@@ -1,14 +1,20 @@
1
1
  "use strict";
2
+ var __importDefault = (this && this.__importDefault) || function (mod) {
3
+ return (mod && mod.__esModule) ? mod : { "default": mod };
4
+ };
2
5
  Object.defineProperty(exports, "__esModule", { value: true });
3
6
  exports.createJitoDontFrontTransaction = createJitoDontFrontTransaction;
4
- exports.createCustomComputeBudgetInstruction = createCustomComputeBudgetInstruction;
5
7
  exports.createCustomComputeBudgetInstructionWithJitoDontFront = createCustomComputeBudgetInstructionWithJitoDontFront;
8
+ const dotenv_1 = __importDefault(require("dotenv"));
9
+ dotenv_1.default.config();
6
10
  const web3_js_1 = require("@solana/web3.js");
7
11
  const web3_js_2 = require("@solana/web3.js");
8
12
  const web3_js_3 = require("@solana/web3.js");
13
+ const jitodontfrontPubkey = process.env.JITODONTFRONT_PUBKEY || 'jitodontfront111111111111111111111111111111';
14
+ console.log('jitodontfrontPubkey', jitodontfrontPubkey);
9
15
  function createJitoDontFrontTransaction(recentBlockhash, tipPayer) {
10
16
  const jitoDontFrontTransaction = new web3_js_2.Transaction();
11
- jitoDontFrontTransaction.add(createCustomComputeBudgetInstruction(tipPayer.publicKey, new web3_js_3.PublicKey('jitodontfront111111111111111111111111111111'), 100000));
17
+ jitoDontFrontTransaction.add(createCustomComputeBudgetInstruction(tipPayer.publicKey, new web3_js_3.PublicKey(jitodontfrontPubkey), 100000));
12
18
  jitoDontFrontTransaction.recentBlockhash = recentBlockhash;
13
19
  jitoDontFrontTransaction.feePayer = tipPayer.publicKey;
14
20
  jitoDontFrontTransaction.sign(tipPayer);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@clonegod/ttd-sol-common",
3
- "version": "1.0.182",
3
+ "version": "1.0.184",
4
4
  "description": "",
5
5
  "main": "dist/index.js",
6
6
  "types": "types/index.d.ts",