Skip to content

Commit

Permalink
lint fix
Browse files Browse the repository at this point in the history
  • Loading branch information
oveddan committed Nov 29, 2023
1 parent 9025ddf commit be9e9db
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 10 deletions.
14 changes: 11 additions & 3 deletions packages/protocol-sdk/src/premint/premint-client.ts
Original file line number Diff line number Diff line change
Expand Up @@ -530,7 +530,7 @@ class PremintClient {
isValid: boolean;
recoveredSigner: Address | undefined;
}> {
const {isAuthorized, recoveredAddress }= await isValidSignature({
const { isAuthorized, recoveredAddress } = await isValidSignature({
chainId: this.chain.id,
signature: data.signature as Hex,
premintConfig: convertPremintV1(data.premint),
Expand Down Expand Up @@ -599,7 +599,12 @@ class PremintClient {
quantityToMint: number;
mintComment?: string;
};
}): Promise<SimulateContractParameters<typeof zoraCreator1155PremintExecutorImplABI, "premint">> {
}): Promise<
SimulateContractParameters<
typeof zoraCreator1155PremintExecutorImplABI,
"premint"
>
> {
if (mintArguments && mintArguments?.quantityToMint < 1) {
throw new Error("Quantity to mint cannot be below 1");
}
Expand All @@ -626,7 +631,10 @@ class PremintClient {
value,
address: getPremintExecutorAddress(),
args,
} satisfies SimulateContractParameters<typeof zoraCreator1155PremintExecutorImplABI, "premint">;
} satisfies SimulateContractParameters<
typeof zoraCreator1155PremintExecutorImplABI,
"premint"
>;

return request;
}
Expand Down
13 changes: 6 additions & 7 deletions packages/protocol-sdk/src/premint/preminter.ts
Original file line number Diff line number Diff line change
Expand Up @@ -200,11 +200,7 @@ export async function isAuthorizedToCreatePremint({
abi: preminterAbi,
address: getPremintExecutorAddress(),
functionName: "isAuthorizedToCreatePremint",
args: [
signer,
collection.contractAdmin,
collectionAddress
],
args: [signer, collection.contractAdmin, collectionAddress],
});
}

Expand Down Expand Up @@ -257,7 +253,10 @@ export async function isValidSignature({
chainId: number;
publicClient: PublicClient;
} & PremintConfigAndVersion): Promise<IsValidSignatureReturn> {
const tokenContract = await getPremintCollectionAddress({ collection, publicClient });
const tokenContract = await getPremintCollectionAddress({
collection,
publicClient,
});
const recoveredAddress = await tryRecoverPremintSigner({
...premintConfigAndVersion,
signature,
Expand All @@ -277,7 +276,7 @@ export async function isValidSignature({
collectionAddress: tokenContract,
publicClient,
signature,
...premintConfigAndVersion
...premintConfigAndVersion,
});

return {
Expand Down

0 comments on commit be9e9db

Please sign in to comment.