Skip to content

Commit 690c417

Browse files
committed
Merge remote-tracking branch 'origin/ph/txWorkerRedis' into ph/txWorkerRedis
2 parents 2b560d5 + a713fea commit 690c417

File tree

17 files changed

+55
-17
lines changed

17 files changed

+55
-17
lines changed

src/db/transactions/queueTx.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ interface QueueTxParams {
1010
chainId: number;
1111
extension: ContractExtension;
1212
// TODO: These shouldn't be in here
13-
deployedContractAddress?: string;
13+
deployedContractAddress?: Address;
1414
deployedContractType?: string;
1515
simulateTx?: boolean;
1616
idempotencyKey?: string;

src/server/routes/contract/extensions/accountFactory/write/createAccount.ts

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
import { Static, Type } from "@sinclair/typebox";
22
import { FastifyInstance } from "fastify";
33
import { StatusCodes } from "http-status-codes";
4+
import { Address } from "thirdweb";
45
import { queueTx } from "../../../../../../db/transactions/queueTx";
56
import { getContract } from "../../../../../../utils/cache/getContract";
67
import { prebuiltDeployResponseSchema } from "../../../../../schemas/prebuilts";
@@ -76,10 +77,10 @@ export const createAccount = async (fastify: FastifyInstance) => {
7677
extraData,
7778
);
7879
const deployedAddress =
79-
await contract.accountFactory.predictAccountAddress(
80+
(await contract.accountFactory.predictAccountAddress(
8081
adminAddress,
8182
extraData,
82-
);
83+
)) as Address;
8384

8485
const queueId = await queueTx({
8586
tx,

src/server/routes/deploy/prebuilt.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
import { Static, Type } from "@sinclair/typebox";
22
import { FastifyInstance } from "fastify";
33
import { StatusCodes } from "http-status-codes";
4+
import { Address } from "thirdweb";
45
import { queueTx } from "../../../db/transactions/queueTx";
56
import { getSdk } from "../../../utils/cache/getSdk";
67
import { contractDeployBasicSchema } from "../../schemas/contract";
@@ -93,7 +94,7 @@ export async function deployPrebuilt(fastify: FastifyInstance) {
9394
compilerOptions,
9495
},
9596
);
96-
const deployedAddress = await tx.simulate();
97+
const deployedAddress = (await tx.simulate()) as Address;
9798

9899
const queueId = await queueTx({
99100
tx,

src/server/routes/deploy/prebuilts/edition.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
import { Static, Type } from "@sinclair/typebox";
22
import { FastifyInstance } from "fastify";
33
import { StatusCodes } from "http-status-codes";
4+
import { Address } from "thirdweb";
45
import { queueTx } from "../../../../db/transactions/queueTx";
56
import { getSdk } from "../../../../utils/cache/getSdk";
67
import { contractDeployBasicSchema } from "../../../schemas/contract";
@@ -98,7 +99,7 @@ export async function deployPrebuiltEdition(fastify: FastifyInstance) {
9899
compilerOptions,
99100
},
100101
);
101-
const deployedAddress = await tx.simulate();
102+
const deployedAddress = (await tx.simulate()) as Address;
102103

103104
const queueId = await queueTx({
104105
tx,

src/server/routes/deploy/prebuilts/editionDrop.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
import { Static, Type } from "@sinclair/typebox";
22
import { FastifyInstance } from "fastify";
33
import { StatusCodes } from "http-status-codes";
4+
import { Address } from "thirdweb";
45
import { queueTx } from "../../../../db/transactions/queueTx";
56
import { getSdk } from "../../../../utils/cache/getSdk";
67
import { contractDeployBasicSchema } from "../../../schemas/contract";
@@ -98,7 +99,7 @@ export async function deployPrebuiltEditionDrop(fastify: FastifyInstance) {
9899
compilerOptions,
99100
},
100101
);
101-
const deployedAddress = await tx.simulate();
102+
const deployedAddress = (await tx.simulate()) as Address;
102103

103104
const queueId = await queueTx({
104105
tx,

src/server/routes/deploy/prebuilts/marketplaceV3.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
import { Static, Type } from "@sinclair/typebox";
22
import { FastifyInstance } from "fastify";
33
import { StatusCodes } from "http-status-codes";
4+
import { Address } from "thirdweb";
45
import { queueTx } from "../../../../db/transactions/queueTx";
56
import { getSdk } from "../../../../utils/cache/getSdk";
67
import { contractDeployBasicSchema } from "../../../schemas/contract";
@@ -89,7 +90,7 @@ export async function deployPrebuiltMarketplaceV3(fastify: FastifyInstance) {
8990
compilerOptions,
9091
},
9192
);
92-
const deployedAddress = await tx.simulate();
93+
const deployedAddress = (await tx.simulate()) as Address;
9394

9495
const queueId = await queueTx({
9596
tx,

src/server/routes/deploy/prebuilts/multiwrap.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
import { Static, Type } from "@sinclair/typebox";
22
import { FastifyInstance } from "fastify";
33
import { StatusCodes } from "http-status-codes";
4+
import { Address } from "thirdweb";
45
import { queueTx } from "../../../../db/transactions/queueTx";
56
import { getSdk } from "../../../../utils/cache/getSdk";
67
import { contractDeployBasicSchema } from "../../../schemas/contract";
@@ -92,7 +93,7 @@ export async function deployPrebuiltMultiwrap(fastify: FastifyInstance) {
9293
compilerOptions,
9394
},
9495
);
95-
const deployedAddress = await tx.simulate();
96+
const deployedAddress = (await tx.simulate()) as Address;
9697

9798
const queueId = await queueTx({
9899
tx,

src/server/routes/deploy/prebuilts/nftCollection.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
import { Static, Type } from "@sinclair/typebox";
22
import { FastifyInstance } from "fastify";
33
import { StatusCodes } from "http-status-codes";
4+
import { Address } from "thirdweb";
45
import { queueTx } from "../../../../db/transactions/queueTx";
56
import { getSdk } from "../../../../utils/cache/getSdk";
67
import { contractDeployBasicSchema } from "../../../schemas/contract";
@@ -95,7 +96,7 @@ export async function deployPrebuiltNFTCollection(fastify: FastifyInstance) {
9596
compilerOptions,
9697
},
9798
);
98-
const deployedAddress = await tx.simulate();
99+
const deployedAddress = (await tx.simulate()) as Address;
99100

100101
const queueId = await queueTx({
101102
tx,

src/server/routes/deploy/prebuilts/nftDrop.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
import { Static, Type } from "@sinclair/typebox";
22
import { FastifyInstance } from "fastify";
33
import { StatusCodes } from "http-status-codes";
4+
import { Address } from "thirdweb";
45
import { queueTx } from "../../../../db/transactions/queueTx";
56
import { getSdk } from "../../../../utils/cache/getSdk";
67
import { contractDeployBasicSchema } from "../../../schemas/contract";
@@ -98,7 +99,7 @@ export async function deployPrebuiltNFTDrop(fastify: FastifyInstance) {
9899
compilerOptions,
99100
},
100101
);
101-
const deployedAddress = await tx.simulate();
102+
const deployedAddress = (await tx.simulate()) as Address;
102103

103104
const queueId = await queueTx({
104105
tx,

src/server/routes/deploy/prebuilts/pack.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
import { Static, Type } from "@sinclair/typebox";
22
import { FastifyInstance } from "fastify";
33
import { StatusCodes } from "http-status-codes";
4+
import { Address } from "thirdweb";
45
import { queueTx } from "../../../../db/transactions/queueTx";
56
import { getSdk } from "../../../../utils/cache/getSdk";
67
import { contractDeployBasicSchema } from "../../../schemas/contract";
@@ -94,7 +95,7 @@ export async function deployPrebuiltPack(fastify: FastifyInstance) {
9495
compilerOptions,
9596
},
9697
);
97-
const deployedAddress = await tx.simulate();
98+
const deployedAddress = (await tx.simulate()) as Address;
9899

99100
const queueId = await queueTx({
100101
tx,

0 commit comments

Comments
 (0)