Skip to content

Conversation

@Aniket6990
Copy link
Contributor

No description provided.

const params = params_ === undefined ? [] : params_;

logger.success("Waiting for confirmation...");
const useContract: useContractType = {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do not use variable name useContract as this name is generally used as a hook.


const settingsGasLimit = (await getConfiguration().get("gasLimit")) as number;

const value =
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

When we create the input JSON for payable functions create the JSON with a value field. We should get all the necessary parameters from the input `JSON. Also optionally keep this input.


export const MutableFunctionCall = async (
context: ExtensionContext,
state: string,
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

state param should be renamed to stateMutability.

getSignedContract,
} from "../networks";

export const MutableFunctionCall = async (
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

function names should always start with a smallcap letter.

value: found.value,
});
}
const params_ = abiItem.inputs?.map((e: any) => e.value);
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think the params should be read inside the mutable & immutable call functions as now the params will contain the payable value.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants