Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@devprotocol/dev-kit

Package Overview
Dependencies
Maintainers
3
Versions
140
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@devprotocol/dev-kit - npm Package Compare versions

Comparing version 5.5.3-alpha.1 to 5.5.3-alpha.2

182

dist/dev-kit.d.ts

@@ -339,2 +339,48 @@ import { TransactionResponse, Provider } from '@ethersproject/abstract-provider';

declare const lockupAbi: ({
inputs: {
internalType: string;
name: string;
type: string;
}[];
payable: boolean;
stateMutability: string;
type: string;
anonymous?: undefined;
name?: undefined;
constant?: undefined;
outputs?: undefined;
} | {
anonymous: boolean;
inputs: {
indexed: boolean;
internalType: string;
name: string;
type: string;
}[];
name: string;
type: string;
payable?: undefined;
stateMutability?: undefined;
constant?: undefined;
outputs?: undefined;
} | {
constant: boolean;
inputs: {
internalType: string;
name: string;
type: string;
}[];
name: string;
outputs: {
internalType: string;
name: string;
type: string;
}[];
payable: boolean;
stateMutability: string;
type: string;
anonymous?: undefined;
})[];
declare const devAbi: ({

@@ -432,3 +478,3 @@ inputs: {

declare const lockupAbi: ({
declare const marketFactoryAbi: ({
inputs: {

@@ -479,3 +525,3 @@ internalType: string;

declare const marketFactoryAbi: ({
declare const metricsFactoryAbi: ({
inputs: {

@@ -526,3 +572,4 @@ internalType: string;

declare const metricsAbi: ({
declare const metricsGroupAbi: {
constant: boolean;
inputs: {

@@ -533,11 +580,2 @@ internalType: string;

}[];
payable: boolean;
stateMutability: string;
type: string;
constant?: undefined;
name?: undefined;
outputs?: undefined;
} | {
constant: boolean;
inputs: never[];
name: string;

@@ -552,5 +590,5 @@ outputs: {

type: string;
})[];
}[];
declare const metricsGroupAbi: {
declare const policyAbi: {
constant: boolean;

@@ -573,3 +611,3 @@ inputs: {

declare const policyFactoryAbi: ({
declare const metricsAbi: ({
inputs: {

@@ -583,21 +621,6 @@ internalType: string;

type: string;
anonymous?: undefined;
constant?: undefined;
name?: undefined;
constant?: undefined;
outputs?: undefined;
} | {
anonymous: boolean;
inputs: {
indexed: boolean;
internalType: string;
name: string;
type: string;
}[];
name: string;
type: string;
payable?: undefined;
stateMutability?: undefined;
constant?: undefined;
outputs?: undefined;
} | {
constant: boolean;

@@ -614,20 +637,5 @@ inputs: never[];

type: string;
anonymous?: undefined;
} | {
constant: boolean;
inputs: {
internalType: string;
name: string;
type: string;
}[];
name: string;
outputs: never[];
payable: boolean;
stateMutability: string;
type: string;
anonymous?: undefined;
})[];
declare const policyAbi: {
constant: boolean;
declare const policyFactoryAbi: ({
inputs: {

@@ -638,22 +646,5 @@ internalType: string;

}[];
name: string;
outputs: {
internalType: string;
name: string;
type: string;
}[];
payable: boolean;
stateMutability: string;
type: string;
}[];
declare const policyGroupAbi: ({
inputs: {
internalType: string;
name: string;
type: string;
}[];
payable: boolean;
stateMutability: string;
type: string;
anonymous?: undefined;

@@ -679,3 +670,5 @@ name?: undefined;

constant: boolean;
inputs: {
inputs: never[];
name: string;
outputs: {
internalType: string;

@@ -685,4 +678,9 @@ name: string;

}[];
name: string;
outputs: {
payable: boolean;
stateMutability: string;
type: string;
anonymous?: undefined;
} | {
constant: boolean;
inputs: {
internalType: string;

@@ -692,2 +690,4 @@ name: string;

}[];
name: string;
outputs: never[];
payable: boolean;

@@ -699,3 +699,3 @@ stateMutability: string;

declare const metricsFactoryAbi: ({
declare const policyGroupAbi: ({
inputs: {

@@ -746,3 +746,3 @@ internalType: string;

declare const propertyAbi: ({
declare const propertyFactoryAbi: ({
inputs: {

@@ -793,3 +793,3 @@ internalType: string;

declare const propertyFactoryAbi: ({
declare const propertyAbi: ({
inputs: {

@@ -882,3 +882,16 @@ internalType: string;

declare const sTokensAbi: ({
declare const withdrawAbi: ({
inputs: {
internalType: string;
name: string;
type: string;
}[];
payable: boolean;
stateMutability: string;
type: string;
anonymous?: undefined;
name?: undefined;
constant?: undefined;
outputs?: undefined;
} | {
anonymous: boolean;

@@ -893,5 +906,8 @@ inputs: {

type: string;
payable?: undefined;
stateMutability?: undefined;
constant?: undefined;
outputs?: undefined;
stateMutability?: undefined;
} | {
constant: boolean;
inputs: {

@@ -908,2 +924,3 @@ internalType: string;

}[];
payable: boolean;
stateMutability: string;

@@ -914,16 +931,3 @@ type: string;

declare const withdrawAbi: ({
inputs: {
internalType: string;
name: string;
type: string;
}[];
payable: boolean;
stateMutability: string;
type: string;
anonymous?: undefined;
name?: undefined;
constant?: undefined;
outputs?: undefined;
} | {
declare const sTokensAbi: ({
anonymous: boolean;

@@ -938,8 +942,5 @@ inputs: {

type: string;
payable?: undefined;
outputs?: undefined;
stateMutability?: undefined;
constant?: undefined;
outputs?: undefined;
} | {
constant: boolean;
inputs: {

@@ -956,3 +957,2 @@ internalType: string;

}[];
payable: boolean;
stateMutability: string;

@@ -959,0 +959,0 @@ type: string;

@@ -103,2 +103,4 @@ import { ethers, BigNumber, providers } from 'ethers'

type SignableProvider = providers.JsonRpcProvider | providers.Web3Provider
export const execute: ExecuteFunction = async <

@@ -110,9 +112,9 @@ T = string,

) => {
const signer = (opts.contract?.provider as providers.JsonRpcProvider)
?.getSigner
const signer =
typeof (opts.contract?.provider as SignableProvider)?.getSigner ===
'function'
? (opts.contract.provider as SignableProvider).getSigner()
: undefined
const contract =
opts.mutation && signer ? opts.contract.connect(signer()) : opts.contract
const from = signer ? await signer().getAddress() : undefined
// eslint-disable-next-line functional/no-expression-statement
console.log({ signer, from })
opts.mutation && signer ? opts.contract.connect(signer) : opts.contract
const args =

@@ -124,10 +126,7 @@ opts.args === undefined

: [...opts.args]
const overrides =
opts.mutation && opts.overrides
? { from, ...opts.overrides.overrides }
: { from }
const argsOverrided = opts.mutation ? [...(args || []), overrides] : args
const argsOverrided =
opts.mutation && opts.overrides?.overrides
? [...(args || []), opts.overrides.overrides]
: args
const method = contract[opts.method]
// eslint-disable-next-line functional/no-expression-statement
console.log({ argsOverrided })
const res = await (argsOverrided === undefined

@@ -139,11 +138,6 @@ ? method()

.catch(() => {
const fallbackOverrides =
const retryArgs =
opts.mutation && opts.overrides?.fallback
? { from, ...opts.overrides.fallback }
: { from }
const retryArgs = opts.mutation
? [...(args || []), fallbackOverrides]
: args
// eslint-disable-next-line functional/no-expression-statement
console.log({ retryArgs })
? [...(args || []), opts.overrides.fallback]
: args
return retryArgs === undefined ? method() : method.apply(N, retryArgs)

@@ -150,0 +144,0 @@ })

{
"name": "@devprotocol/dev-kit",
"version": "5.5.3-alpha.1",
"version": "5.5.3-alpha.2",
"description": "Dev Kit for JavaScript",

@@ -5,0 +5,0 @@ "author": "abyssparanoia",

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc