Skip to content

Commit 8f668fe

Browse files
authored
Revert "refactor: clearer folder organization (#792)" (#795)
This reverts commit 5d405f0.
1 parent 5d405f0 commit 8f668fe

File tree

449 files changed

+1000
-978
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

449 files changed

+1000
-978
lines changed

.vscode/settings.json

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
{
2+
"editor.codeActionsOnSave": {
3+
"source.organizeImports": "explicit",
4+
"source.eslint.fixAll": "explicit"
5+
},
6+
"editor.defaultFormatter": "esbenp.prettier-vscode",
7+
"editor.formatOnSave": true,
8+
"eslint.rules.customizations": [{ "rule": "*", "severity": "warn" }],
9+
"typescript.tsdk": "node_modules/typescript/lib",
10+
"typescript.enablePromptUseWorkspaceTsdk": true,
11+
"[prisma]": {
12+
"editor.defaultFormatter": "Prisma.prisma"
13+
},
14+
"[typescript]": {
15+
"editor.defaultFormatter": "biomejs.biome"
16+
}
17+
}

Dockerfile

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -64,7 +64,6 @@ COPY --from=build /app/package.json .
6464
COPY --from=build /app/node_modules ./node_modules
6565
COPY --from=build /app/src/prisma/* ./src/prisma/
6666
COPY --from=build /app/dist ./dist
67-
COPY --from=build /app/scripts ./dist/scripts
6867

6968
# Replace the schema path in the package.json file
7069
RUN sed -i 's_"schema": "./src/prisma/schema.prisma"_"schema": "./dist/prisma/schema.prisma"_g' package.json

package.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,8 +13,8 @@
1313
"dev:run": "npx nodemon --watch 'src/**/*.ts' --exec 'npx tsx ./src/index.ts' --files src/index.ts",
1414
"build": "rm -rf dist && tsc -p ./tsconfig.json --outDir dist",
1515
"build:docker": "docker build . -f Dockerfile -t prod",
16-
"generate:sdk": "npx tsx ./scripts/generate-sdk && cd ./sdk && yarn build",
17-
"prisma:setup:dev": "npx tsx ./scripts/setup-db.ts",
16+
"generate:sdk": "npx tsx ./src/scripts/generate-sdk && cd ./sdk && yarn build",
17+
"prisma:setup:dev": "npx tsx ./src/scripts/setup-db.ts",
1818
"prisma:setup:prod": "npx tsx ./dist/scripts/setup-db.js",
1919
"start": "yarn prisma:setup:prod && yarn start:migrations && yarn start:run",
2020
"start:migrations": "npx tsx ./dist/scripts/apply-migrations.js",
File renamed without changes.

src/shared/db/chainIndexers/getChainIndexer.ts renamed to src/db/chainIndexers/getChainIndexer.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
import { Prisma } from "@prisma/client";
2-
import type { PrismaTransaction } from "../../schemas/prisma";
2+
import type { PrismaTransaction } from "../../schema/prisma";
33
import { getPrismaWithPostgresTx } from "../client";
44

55
interface GetLastIndexedBlockParams {

src/shared/db/chainIndexers/upsertChainIndexer.ts renamed to src/db/chainIndexers/upsertChainIndexer.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import type { PrismaTransaction } from "../../schemas/prisma";
1+
import type { PrismaTransaction } from "../../schema/prisma";
22
import { getPrismaWithPostgresTx } from "../client";
33

44
interface UpsertChainIndexerParams {

src/shared/db/client.ts renamed to src/db/client.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
import { PrismaClient } from "@prisma/client";
2-
import pg, { type Knex } from "knex";
3-
import type { PrismaTransaction } from "../schemas/prisma";
2+
import pg, { Knex } from "knex";
3+
import { PrismaTransaction } from "../schema/prisma";
44
import { env } from "../utils/env";
55

66
export const prisma = new PrismaClient({
@@ -26,7 +26,7 @@ export const isDatabaseReachable = async () => {
2626
try {
2727
await prisma.walletDetails.findFirst();
2828
return true;
29-
} catch {
29+
} catch (error) {
3030
return false;
3131
}
3232
};

src/shared/db/configuration/getConfiguration.ts renamed to src/db/configuration/getConfiguration.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -7,9 +7,9 @@ import type {
77
AwsWalletConfiguration,
88
GcpWalletConfiguration,
99
ParsedConfig,
10-
} from "../../schemas/config";
11-
import { WalletType } from "../../schemas/wallet";
12-
import { mandatoryAllowedCorsUrls } from "../../../server/utils/cors-urls";
10+
} from "../../schema/config";
11+
import { WalletType } from "../../schema/wallet";
12+
import { mandatoryAllowedCorsUrls } from "../../server/utils/cors-urls";
1313
import type { networkResponseSchema } from "../../utils/cache/getSdk";
1414
import { decrypt } from "../../utils/crypto";
1515
import { env } from "../../utils/env";

src/shared/db/contractEventLogs/createContractEventLogs.ts renamed to src/db/contractEventLogs/createContractEventLogs.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
1-
import type { ContractEventLogs, Prisma } from "@prisma/client";
2-
import type { PrismaTransaction } from "../../schemas/prisma";
1+
import { ContractEventLogs, Prisma } from "@prisma/client";
2+
import { PrismaTransaction } from "../../schema/prisma";
33
import { getPrismaWithPostgresTx } from "../client";
44

55
export interface BulkInsertContractLogsParams {

src/shared/db/contractTransactionReceipts/createContractTransactionReceipts.ts renamed to src/db/contractTransactionReceipts/createContractTransactionReceipts.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
import { ContractTransactionReceipts, Prisma } from "@prisma/client";
2-
import { PrismaTransaction } from "../../schemas/prisma";
2+
import { PrismaTransaction } from "../../schema/prisma";
33
import { getPrismaWithPostgresTx } from "../client";
44

55
export interface BulkInsertContractLogsParams {
File renamed without changes.
File renamed without changes.

src/shared/db/keypair/insert.ts renamed to src/db/keypair/insert.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
1-
import type { Keypairs } from "@prisma/client";
2-
import { createHash } from "node:crypto";
3-
import type { KeypairAlgorithm } from "../../schemas/keypair";
1+
import { Keypairs } from "@prisma/client";
2+
import { createHash } from "crypto";
3+
import { KeypairAlgorithm } from "../../server/schemas/keypairs";
44
import { prisma } from "../client";
55

66
export const insertKeypair = async ({
File renamed without changes.

src/shared/db/permissions/getPermissions.ts renamed to src/db/permissions/getPermissions.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import { Permission } from "../../schemas/auth";
1+
import { Permission } from "../../server/schemas/auth";
22
import { env } from "../../utils/env";
33
import { prisma } from "../client";
44

File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.

src/shared/db/transactions/queueTx.ts renamed to src/db/transactions/queueTx.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,11 @@
11
import type { DeployTransaction, Transaction } from "@thirdweb-dev/sdk";
22
import type { ERC4337EthersSigner } from "@thirdweb-dev/wallets/dist/declarations/src/evm/connectors/smart-wallet/lib/erc4337-signer";
33
import { ZERO_ADDRESS, type Address } from "thirdweb";
4-
import type { ContractExtension } from "../../schemas/extension";
4+
import type { ContractExtension } from "../../schema/extension";
5+
import { parseTransactionOverrides } from "../../server/utils/transactionOverrides";
56
import { maybeBigInt, normalizeAddress } from "../../utils/primitiveTypes";
67
import { insertTransaction } from "../../utils/transaction/insertTransaction";
78
import type { InsertedTransaction } from "../../utils/transaction/types";
8-
import { parseTransactionOverrides } from "../../../server/utils/transactionOverrides";
99

1010
interface QueueTxParams {
1111
// we should move away from Transaction type (v4 SDK)

src/shared/db/wallets/createWalletDetails.ts renamed to src/db/wallets/createWalletDetails.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
import type { Address } from "thirdweb";
2-
import type { PrismaTransaction } from "../../schemas/prisma";
2+
import type { PrismaTransaction } from "../../schema/prisma";
33
import { encrypt } from "../../utils/crypto";
44
import { getPrismaWithPostgresTx } from "../client";
55

src/shared/db/wallets/getAllWallets.ts renamed to src/db/wallets/getAllWallets.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import { PrismaTransaction } from "../../schemas/prisma";
1+
import { PrismaTransaction } from "../../schema/prisma";
22
import { getPrismaWithPostgresTx } from "../client";
33

44
interface GetAllWalletsParams {

src/shared/db/wallets/getWalletDetails.ts renamed to src/db/wallets/getWalletDetails.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
import { getAddress } from "thirdweb";
22
import { z } from "zod";
3-
import type { PrismaTransaction } from "../../schemas/prisma";
3+
import type { PrismaTransaction } from "../../schema/prisma";
44
import { getConfig } from "../../utils/cache/getConfig";
55
import { decrypt } from "../../utils/crypto";
66
import { env } from "../../utils/env";

src/shared/db/wallets/nonceMap.ts renamed to src/db/wallets/nonceMap.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import type { Address } from "thirdweb";
1+
import { Address } from "thirdweb";
22
import { env } from "../../utils/env";
33
import { normalizeAddress } from "../../utils/primitiveTypes";
44
import { redis } from "../../utils/redis/redis";
File renamed without changes.

src/shared/db/webhooks/createWebhook.ts renamed to src/db/webhooks/createWebhook.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
import { Webhooks } from "@prisma/client";
22
import { createHash, randomBytes } from "crypto";
3-
import { WebhooksEventTypes } from "../../schemas/webhooks";
3+
import { WebhooksEventTypes } from "../../schema/webhooks";
44
import { prisma } from "../client";
55

66
interface CreateWebhooksParams {
File renamed without changes.

src/index.ts

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,8 @@
11
import "./polyfill";
2-
import "./tracer";
3-
42
import { initServer } from "./server";
5-
import { env } from "./shared/utils/env";
6-
import { logger } from "./shared/utils/logger";
3+
import { env } from "./utils/env";
4+
import { logger } from "./utils/logger";
5+
import "./utils/tracer";
76
import { initWorker } from "./worker";
87
import { CancelRecycledNoncesQueue } from "./worker/queues/cancelRecycledNoncesQueue";
98
import { MigratePostgresTransactionsQueue } from "./worker/queues/migratePostgresTransactionsQueue";
File renamed without changes.

src/polyfill.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import * as crypto from "node:crypto";
1+
import * as crypto from "crypto";
22

33
if (typeof globalThis.crypto === "undefined") {
44
(globalThis as any).crypto = crypto;
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.

scripts/apply-migrations.ts renamed to src/scripts/apply-migrations.ts

Lines changed: 3 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,6 @@
1-
import { logger } from "../src/shared/utils/logger";
2-
import {
3-
acquireLock,
4-
releaseLock,
5-
waitForLock,
6-
} from "../src/shared/utils/redis/lock";
7-
import { redis } from "../src/shared/utils/redis/redis";
1+
import { logger } from "../utils/logger";
2+
import { acquireLock, releaseLock, waitForLock } from "../utils/redis/lock";
3+
import { redis } from "../utils/redis/redis";
84

95
const MIGRATION_LOCK_TTL_SECONDS = 60;
106

File renamed without changes.

scripts/setup-db.ts renamed to src/scripts/setup-db.ts

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
1-
import { execSync } from "node:child_process";
2-
import { prisma } from "../src/shared/db/client";
1+
import { execSync } from "child_process";
2+
import { prisma } from "../db/client";
33

44
const main = async () => {
55
const [{ exists: hasWalletsTable }]: [{ exists: boolean }] =
@@ -14,8 +14,8 @@ const main = async () => {
1414

1515
const schema =
1616
process.env.NODE_ENV === "production"
17-
? "./dist/prisma/schema.prisma"
18-
: "./src/prisma/schema.prisma";
17+
? `./dist/prisma/schema.prisma`
18+
: `./src/prisma/schema.prisma`;
1919

2020
if (hasWalletsTable) {
2121
execSync(`yarn prisma migrate reset --force --schema ${schema}`, {

src/server/index.ts

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -3,11 +3,11 @@ import fastify, { type FastifyInstance } from "fastify";
33
import * as fs from "node:fs";
44
import path from "node:path";
55
import { URL } from "node:url";
6-
import { clearCacheCron } from "../shared/utils/cron/clearCacheCron";
7-
import { env } from "../shared/utils/env";
8-
import { logger } from "../shared/utils/logger";
9-
import { metricsServer } from "../shared/utils/prometheus";
10-
import { withServerUsageReporting } from "../shared/utils/usage";
6+
import { clearCacheCron } from "../utils/cron/clearCacheCron";
7+
import { env } from "../utils/env";
8+
import { logger } from "../utils/logger";
9+
import { metricsServer } from "../utils/prometheus";
10+
import { withServerUsageReporting } from "../utils/usage";
1111
import { updateTxListener } from "./listeners/updateTxListener";
1212
import { withAdminRoutes } from "./middleware/adminRoutes";
1313
import { withAuth } from "./middleware/auth";

src/server/listeners/updateTxListener.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
1-
import { knex } from "../../shared/db/client";
2-
import { TransactionDB } from "../../shared/db/transactions/db";
3-
import { logger } from "../../shared/utils/logger";
1+
import { knex } from "../../db/client";
2+
import { TransactionDB } from "../../db/transactions/db";
3+
import { logger } from "../../utils/logger";
44
import { toTransactionSchema } from "../schemas/transaction";
55
import { subscriptionsData } from "../schemas/websocket";
66
import {

src/server/middleware/adminRoutes.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ import type { Queue } from "bullmq";
55
import type { FastifyInstance } from "fastify";
66
import { StatusCodes } from "http-status-codes";
77
import { timingSafeEqual } from "node:crypto";
8-
import { env } from "../../shared/utils/env";
8+
import { env } from "../../utils/env";
99
import { CancelRecycledNoncesQueue } from "../../worker/queues/cancelRecycledNoncesQueue";
1010
import { MigratePostgresTransactionsQueue } from "../../worker/queues/migratePostgresTransactionsQueue";
1111
import { MineTransactionQueue } from "../../worker/queues/mineTransactionQueue";

src/server/middleware/auth.ts

Lines changed: 15 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -5,25 +5,25 @@ import {
55
type ThirdwebAuthUser,
66
} from "@thirdweb-dev/auth/fastify";
77
import { AsyncWallet } from "@thirdweb-dev/wallets/evm/wallets/async";
8-
import { createHash } from "node:crypto";
8+
import { createHash } from "crypto";
99
import type { FastifyInstance } from "fastify";
1010
import type { FastifyRequest } from "fastify/types/request";
1111
import jsonwebtoken, { type JwtPayload } from "jsonwebtoken";
1212
import { validate as uuidValidate } from "uuid";
13-
import { getPermissions } from "../../shared/db/permissions/getPermissions";
14-
import { createToken } from "../../shared/db/tokens/createToken";
15-
import { revokeToken } from "../../shared/db/tokens/revokeToken";
16-
import { WebhooksEventTypes } from "../../shared/schemas/webhooks";
17-
import { THIRDWEB_DASHBOARD_ISSUER, handleSiwe } from "../../shared/utils/auth";
18-
import { getAccessToken } from "../../shared/utils/cache/accessToken";
19-
import { getAuthWallet } from "../../shared/utils/cache/authWallet";
20-
import { getConfig } from "../../shared/utils/cache/getConfig";
21-
import { getWebhooksByEventType } from "../../shared/utils/cache/getWebhook";
22-
import { getKeypair } from "../../shared/utils/cache/keypair";
23-
import { env } from "../../shared/utils/env";
24-
import { logger } from "../../shared/utils/logger";
25-
import { sendWebhookRequest } from "../../shared/utils/webhook";
26-
import { Permission } from "../../shared/schemas/auth";
13+
import { getPermissions } from "../../db/permissions/getPermissions";
14+
import { createToken } from "../../db/tokens/createToken";
15+
import { revokeToken } from "../../db/tokens/revokeToken";
16+
import { WebhooksEventTypes } from "../../schema/webhooks";
17+
import { THIRDWEB_DASHBOARD_ISSUER, handleSiwe } from "../../utils/auth";
18+
import { getAccessToken } from "../../utils/cache/accessToken";
19+
import { getAuthWallet } from "../../utils/cache/authWallet";
20+
import { getConfig } from "../../utils/cache/getConfig";
21+
import { getWebhooksByEventType } from "../../utils/cache/getWebhook";
22+
import { getKeypair } from "../../utils/cache/keypair";
23+
import { env } from "../../utils/env";
24+
import { logger } from "../../utils/logger";
25+
import { sendWebhookRequest } from "../../utils/webhook";
26+
import { Permission } from "../schemas/auth";
2727
import { ADMIN_QUEUES_BASEPATH } from "./adminRoutes";
2828
import { OPENAPI_ROUTES } from "./openApi";
2929

src/server/middleware/cors.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
import type { FastifyInstance } from "fastify";
2-
import { getConfig } from "../../shared/utils/cache/getConfig";
2+
import { getConfig } from "../../utils/cache/getConfig";
33
import { ADMIN_QUEUES_BASEPATH } from "./adminRoutes";
44

55
const STANDARD_METHODS = "GET,POST,DELETE,PUT,PATCH,HEAD,PUT,PATCH,POST,DELETE";

src/server/middleware/engineMode.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
import type { FastifyInstance } from "fastify";
2-
import { env } from "../../shared/utils/env";
2+
import { env } from "../../utils/env";
33

44
export function withEnforceEngineMode(server: FastifyInstance) {
55
if (env.ENGINE_MODE === "sandbox") {

src/server/middleware/error.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
import type { FastifyInstance } from "fastify";
22
import { ReasonPhrases, StatusCodes } from "http-status-codes";
33
import { ZodError } from "zod";
4-
import { env } from "../../shared/utils/env";
5-
import { parseEthersError } from "../../shared/utils/ethers";
4+
import { env } from "../../utils/env";
5+
import { parseEthersError } from "../../utils/ethers";
66

77
export type CustomError = {
88
message: string;

src/server/middleware/logs.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
import type { FastifyInstance } from "fastify";
22
import { stringify } from "thirdweb/utils";
3-
import { logger } from "../../shared/utils/logger";
3+
import { logger } from "../../utils/logger";
44
import { ADMIN_QUEUES_BASEPATH } from "./adminRoutes";
55
import { OPENAPI_ROUTES } from "./openApi";
66

src/server/middleware/prometheus.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
import type { FastifyInstance, FastifyReply, FastifyRequest } from "fastify";
2-
import { env } from "../../shared/utils/env";
3-
import { recordMetrics } from "../../shared/utils/prometheus";
2+
import { env } from "../../utils/env";
3+
import { recordMetrics } from "../../utils/prometheus";
44

55
export function withPrometheus(server: FastifyInstance) {
66
if (!env.METRICS_ENABLED) {

src/server/middleware/rateLimit.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
import type { FastifyInstance } from "fastify";
22
import { StatusCodes } from "http-status-codes";
3-
import { env } from "../../shared/utils/env";
4-
import { redis } from "../../shared/utils/redis/redis";
3+
import { env } from "../../utils/env";
4+
import { redis } from "../../utils/redis/redis";
55
import { createCustomError } from "./error";
66
import { OPENAPI_ROUTES } from "./openApi";
77

src/server/middleware/websocket.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
import WebSocketPlugin from "@fastify/websocket";
22
import type { FastifyInstance } from "fastify";
3-
import { logger } from "../../shared/utils/logger";
3+
import { logger } from "../../utils/logger";
44

55
export async function withWebSocket(server: FastifyInstance) {
66
await server.register(WebSocketPlugin, {

src/server/routes/admin/nonces.ts

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
1-
import { type Static, Type } from "@sinclair/typebox";
2-
import type { FastifyInstance } from "fastify";
1+
import { Static, Type } from "@sinclair/typebox";
2+
import { FastifyInstance } from "fastify";
33
import { StatusCodes } from "http-status-codes";
44
import {
5-
type Address,
5+
Address,
66
eth_getTransactionCount,
77
getAddress,
88
getRpcClient,
@@ -12,10 +12,10 @@ import {
1212
lastUsedNonceKey,
1313
recycledNoncesKey,
1414
sentNoncesKey,
15-
} from "../../../shared/db/wallets/walletNonce";
16-
import { getChain } from "../../../shared/utils/chain";
17-
import { redis } from "../../../shared/utils/redis/redis";
18-
import { thirdwebClient } from "../../../shared/utils/sdk";
15+
} from "../../../db/wallets/walletNonce";
16+
import { getChain } from "../../../utils/chain";
17+
import { redis } from "../../../utils/redis/redis";
18+
import { thirdwebClient } from "../../../utils/sdk";
1919
import { AddressSchema } from "../../schemas/address";
2020
import { standardResponseSchema } from "../../schemas/sharedApiSchemas";
2121
import { walletWithAddressParamSchema } from "../../schemas/wallet";

src/server/routes/admin/transaction.ts

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,12 @@
1-
import { type Static, Type } from "@sinclair/typebox";
2-
import type { Queue } from "bullmq";
3-
import type { FastifyInstance } from "fastify";
1+
import { Static, Type } from "@sinclair/typebox";
2+
import { Queue } from "bullmq";
3+
import { FastifyInstance } from "fastify";
44
import { StatusCodes } from "http-status-codes";
55
import { stringify } from "thirdweb/utils";
6-
import { TransactionDB } from "../../../shared/db/transactions/db";
7-
import { getConfig } from "../../../shared/utils/cache/getConfig";
8-
import { maybeDate } from "../../../shared/utils/primitiveTypes";
9-
import { redis } from "../../../shared/utils/redis/redis";
6+
import { TransactionDB } from "../../../db/transactions/db";
7+
import { getConfig } from "../../../utils/cache/getConfig";
8+
import { maybeDate } from "../../../utils/primitiveTypes";
9+
import { redis } from "../../../utils/redis/redis";
1010
import { MineTransactionQueue } from "../../../worker/queues/mineTransactionQueue";
1111
import { SendTransactionQueue } from "../../../worker/queues/sendTransactionQueue";
1212
import { createCustomError } from "../../middleware/error";

0 commit comments

Comments
 (0)