antier-gnosis-safe
Advanced tools
Comparing version
@@ -106,3 +106,3 @@ "use strict"; | ||
const gasLimit = await safe.estimateGas.execTransaction(safeTx.to, safeTx.value, safeTx.data, safeTx.operation, safeTx.safeTxGas, safeTx.baseGas, safeTx.gasPrice, safeTx.gasToken, safeTx.refundReceiver, signatureBytes); | ||
return safe.execTransaction(safeTx.to, safeTx.value, safeTx.data, safeTx.operation, safeTx.safeTxGas, safeTx.baseGas, safeTx.gasPrice, safeTx.gasToken, safeTx.refundReceiver, signatureBytes, overrides || { gasLimit: gasLimit.mul(10) }); | ||
return safe.execTransaction(safeTx.to, safeTx.value, safeTx.data, safeTx.operation, safeTx.safeTxGas, safeTx.baseGas, safeTx.gasPrice, safeTx.gasToken, safeTx.refundReceiver, signatureBytes, overrides || { gasLimit: gasLimit }); | ||
}; | ||
@@ -131,5 +131,2 @@ exports.executeTx = executeTx; | ||
const nonce = await safe.nonce(); | ||
const threshold = await safe.getThreshold(); | ||
const owners = await safe.getOwners(); | ||
console.log('threshold :>> ', threshold.toString(), owners); | ||
const tx = (0, exports.buildContractCall)(contract, method, params, nonce, delegateCall, overrides); | ||
@@ -136,0 +133,0 @@ return (0, exports.executeTxWithSigners)(safe, tx, signs); |
@@ -52,3 +52,2 @@ import { Contract, BigNumber, BigNumberish, Signer, PopulatedTransaction } from "ethers"; | ||
export declare const executeContractCallForSigners: (safe: Contract, contract: Contract, method: string, params: any[], signers: any[], provider: any, delegateCall?: boolean, overrides?: Partial<SafeTransaction>) => Promise<SafeSignature[]>; | ||
export declare const executeContractCallWithSignersBuy: (safe: Contract, contract: Contract, method: string, params: any[], signers: any[], provider: any, delegateCall?: boolean, overrides?: Partial<SafeTransaction>) => Promise<SafeSignature[]>; | ||
export declare const buildSafeTransaction: (template: { | ||
@@ -55,0 +54,0 @@ to: string; |
"use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
exports.buildSafeTransaction = exports.executeContractCallWithSignersBuy = exports.executeContractCallForSigners = exports.executeTxWithSigners = exports.buildContractCall = exports.populateExecuteTx = exports.logGas = exports.buildSignatureBytes = exports.safeSignMessage = exports.signHash = exports.safeSignTypedData = exports.safeApproveHash = exports.calculateSafeMessageHash = exports.calculateSafeTransactionHash = exports.preimageSafeTransactionHash = exports.calculateSafeDomainSeparator = exports.EIP712_SAFE_MESSAGE_TYPE = exports.EIP712_SAFE_TX_TYPE = exports.EIP_DOMAIN = void 0; | ||
exports.buildSafeTransaction = exports.executeContractCallForSigners = exports.executeTxWithSigners = exports.buildContractCall = exports.populateExecuteTx = exports.logGas = exports.buildSignatureBytes = exports.safeSignMessage = exports.signHash = exports.safeSignTypedData = exports.safeApproveHash = exports.calculateSafeMessageHash = exports.calculateSafeTransactionHash = exports.preimageSafeTransactionHash = exports.calculateSafeDomainSeparator = exports.EIP712_SAFE_MESSAGE_TYPE = exports.EIP712_SAFE_TX_TYPE = exports.EIP_DOMAIN = void 0; | ||
const ethers_1 = require("ethers"); | ||
@@ -136,13 +136,2 @@ const constants_1 = require("@ethersproject/constants"); | ||
exports.executeContractCallForSigners = executeContractCallForSigners; | ||
const executeContractCallWithSignersBuy = async (safe, contract, method, params, signers, provider, delegateCall, overrides) => { | ||
const nonceMain = await safe.nonce(); | ||
let non = parseFloat(nonceMain) + 1; | ||
const nonce = { | ||
type: "BigNumber", | ||
hex: "0x0" + non | ||
}; | ||
const tx = (0, exports.buildContractCall)(contract, method, params, nonce, delegateCall, overrides); | ||
return (0, exports.executeTxWithSigners)(safe, tx, signers, provider); | ||
}; | ||
exports.executeContractCallWithSignersBuy = executeContractCallWithSignersBuy; | ||
const buildSafeTransaction = (template) => { | ||
@@ -149,0 +138,0 @@ return { |
@@ -20,5 +20,3 @@ "use strict"; | ||
await p.send("eth_requestAccounts", []); | ||
console.log('p :>> ', p); | ||
s = p.getSigner(0); | ||
console.log('s :>> ', s); | ||
return { | ||
@@ -25,0 +23,0 @@ signer: s, |
{ | ||
"name": "antier-gnosis-safe", | ||
"version": "1.2.13", | ||
"version": "1.2.14", | ||
"description": "", | ||
@@ -5,0 +5,0 @@ "main": "dist/index.js", |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
130604
-1.44%2193
-0.81%