Skip to content

Commit

Permalink
Remove usage of /core (#191)
Browse files Browse the repository at this point in the history
  • Loading branch information
adam-maj authored Oct 3, 2023
1 parent e23bc41 commit ba943ae
Show file tree
Hide file tree
Showing 96 changed files with 173 additions and 298 deletions.
25 changes: 0 additions & 25 deletions core/database/dbConnect.ts

This file was deleted.

24 changes: 0 additions & 24 deletions core/error/customError.ts

This file was deleted.

9 changes: 0 additions & 9 deletions core/error/errorCodes.ts

This file was deleted.

11 changes: 0 additions & 11 deletions core/helpers/index.ts

This file was deleted.

5 changes: 0 additions & 5 deletions core/index.ts

This file was deleted.

15 changes: 0 additions & 15 deletions core/interfaces/index.ts

This file was deleted.

49 changes: 0 additions & 49 deletions core/schema/index.ts

This file was deleted.

41 changes: 0 additions & 41 deletions core/services/benchmark.ts

This file was deleted.

26 changes: 0 additions & 26 deletions core/services/blockchain.ts

This file was deleted.

8 changes: 5 additions & 3 deletions server/api/chain/get.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,12 @@ import { Static, Type } from "@sinclair/typebox";
import { allChains, minimizeChain } from "@thirdweb-dev/chains";
import { FastifyInstance } from "fastify";
import { StatusCodes } from "http-status-codes";
import { createCustomError } from "../../../core/index";
import { chainResponseSchema } from "../../../core/schema";
import { standardResponseSchema } from "../../helpers/sharedApiSchemas";
import { chainRequestQuerystringSchema } from "../../schemas/chain";
import { createCustomError } from "../../middleware/error";
import {
chainRequestQuerystringSchema,
chainResponseSchema,
} from "../../schemas/chain";

// OUPUT
const responseSchema = Type.Object({
Expand Down
2 changes: 1 addition & 1 deletion server/api/chain/getAll.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@ import { Static, Type } from "@sinclair/typebox";
import { allChains, minimizeChain } from "@thirdweb-dev/chains";
import { FastifyInstance } from "fastify";
import { StatusCodes } from "http-status-codes";
import { chainResponseSchema } from "../../../core/schema";
import { standardResponseSchema } from "../../helpers/sharedApiSchemas";
import { chainResponseSchema } from "../../schemas/chain";

// OUPUT
const responseSchema = Type.Object({
Expand Down
2 changes: 1 addition & 1 deletion server/api/contract/extensions/account/write/grantAdmin.ts
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
import { Static, Type } from "@sinclair/typebox";
import { FastifyInstance } from "fastify";
import { StatusCodes } from "http-status-codes";
import { walletAuthSchema } from "../../../../../../core/schema";
import { queueTx } from "../../../../../../src/db/transactions/queueTx";
import {
contractParamSchema,
standardResponseSchema,
transactionWritesResponseSchema,
} from "../../../../../helpers";
import { walletAuthSchema } from "../../../../../schemas/wallet";
import { getChainIdFromChain } from "../../../../../utilities/chain";
import { getContract } from "../../../../../utils/cache/getContract";

Expand Down
Original file line number Diff line number Diff line change
@@ -1,14 +1,14 @@
import { Static } from "@sinclair/typebox";
import { FastifyInstance } from "fastify";
import { StatusCodes } from "http-status-codes";
import { walletAuthSchema } from "../../../../../../core/schema";
import { queueTx } from "../../../../../../src/db/transactions/queueTx";
import {
contractParamSchema,
standardResponseSchema,
transactionWritesResponseSchema,
} from "../../../../../helpers";
import { SessionSchema } from "../../../../../schemas/account";
import { walletAuthSchema } from "../../../../../schemas/wallet";
import { getChainIdFromChain } from "../../../../../utilities/chain";
import { getContract } from "../../../../../utils/cache/getContract";

Expand Down
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
import { Static, Type } from "@sinclair/typebox";
import { FastifyInstance } from "fastify";
import { StatusCodes } from "http-status-codes";
import { walletAuthSchema } from "../../../../../../core/schema";
import { queueTx } from "../../../../../../src/db/transactions/queueTx";
import {
contractParamSchema,
standardResponseSchema,
transactionWritesResponseSchema,
} from "../../../../../helpers";
import { walletAuthSchema } from "../../../../../schemas/wallet";
import { getChainIdFromChain } from "../../../../../utilities/chain";
import { getContract } from "../../../../../utils/cache/getContract";

Expand Down
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
import { Static, Type } from "@sinclair/typebox";
import { FastifyInstance } from "fastify";
import { StatusCodes } from "http-status-codes";
import { walletAuthSchema } from "../../../../../../core/schema";
import { queueTx } from "../../../../../../src/db/transactions/queueTx";
import {
contractParamSchema,
standardResponseSchema,
transactionWritesResponseSchema,
} from "../../../../../helpers";
import { walletAuthSchema } from "../../../../../schemas/wallet";
import { getChainIdFromChain } from "../../../../../utilities/chain";
import { getContract } from "../../../../../utils/cache/getContract";

Expand Down
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
import { Static, Type } from "@sinclair/typebox";
import { FastifyInstance } from "fastify";
import { StatusCodes } from "http-status-codes";
import { walletAuthSchema } from "../../../../../../core/schema";
import { queueTx } from "../../../../../../src/db/transactions/queueTx";
import {
contractParamSchema,
standardResponseSchema,
transactionWritesResponseSchema,
} from "../../../../../helpers";
import { walletAuthSchema } from "../../../../../schemas/wallet";
import { getChainIdFromChain } from "../../../../../utilities/chain";
import { getContract } from "../../../../../utils/cache/getContract";

Expand Down
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
import { Static, Type } from "@sinclair/typebox";
import { FastifyInstance } from "fastify";
import { StatusCodes } from "http-status-codes";
import { walletAuthSchema } from "../../../../../../core/schema";
import { queueTx } from "../../../../../../src/db/transactions/queueTx";
import {
contractParamSchema,
standardResponseSchema,
} from "../../../../../helpers";
import { prebuiltDeployResponseSchema } from "../../../../../schemas/prebuilts";
import { walletAuthSchema } from "../../../../../schemas/wallet";
import { getChainIdFromChain } from "../../../../../utilities/chain";
import { getContract } from "../../../../../utils/cache/getContract";

Expand Down
2 changes: 1 addition & 1 deletion server/api/contract/extensions/erc1155/write/airdrop.ts
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
import { Static, Type } from "@sinclair/typebox";
import { FastifyInstance } from "fastify";
import { StatusCodes } from "http-status-codes";
import { walletAuthSchema } from "../../../../../../core/schema";
import { queueTx } from "../../../../../../src/db/transactions/queueTx";
import {
erc1155ContractParamSchema,
standardResponseSchema,
transactionWritesResponseSchema,
} from "../../../../../helpers/sharedApiSchemas";
import { walletAuthSchema } from "../../../../../schemas/wallet";
import { txOverridesForWriteRequest } from "../../../../../schemas/web3api-overrides";
import { getChainIdFromChain } from "../../../../../utilities/chain";
import { getContract } from "../../../../../utils/cache/getContract";
Expand Down
2 changes: 1 addition & 1 deletion server/api/contract/extensions/erc1155/write/burn.ts
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
import { Static, Type } from "@sinclair/typebox";
import { FastifyInstance } from "fastify";
import { StatusCodes } from "http-status-codes";
import { walletAuthSchema } from "../../../../../../core/schema";
import { queueTx } from "../../../../../../src/db/transactions/queueTx";
import {
erc1155ContractParamSchema,
standardResponseSchema,
transactionWritesResponseSchema,
} from "../../../../../helpers/sharedApiSchemas";
import { walletAuthSchema } from "../../../../../schemas/wallet";
import { txOverridesForWriteRequest } from "../../../../../schemas/web3api-overrides";
import { getChainIdFromChain } from "../../../../../utilities/chain";
import { getContract } from "../../../../../utils/cache/getContract";
Expand Down
2 changes: 1 addition & 1 deletion server/api/contract/extensions/erc1155/write/burnBatch.ts
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
import { Static, Type } from "@sinclair/typebox";
import { FastifyInstance } from "fastify";
import { StatusCodes } from "http-status-codes";
import { walletAuthSchema } from "../../../../../../core/schema";
import { queueTx } from "../../../../../../src/db/transactions/queueTx";
import {
erc1155ContractParamSchema,
standardResponseSchema,
transactionWritesResponseSchema,
} from "../../../../../helpers/sharedApiSchemas";
import { walletAuthSchema } from "../../../../../schemas/wallet";
import { txOverridesForWriteRequest } from "../../../../../schemas/web3api-overrides";
import { getChainIdFromChain } from "../../../../../utilities/chain";
import { getContract } from "../../../../../utils/cache/getContract";
Expand Down
2 changes: 1 addition & 1 deletion server/api/contract/extensions/erc1155/write/claimTo.ts
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
import { Static, Type } from "@sinclair/typebox";
import { FastifyInstance } from "fastify";
import { StatusCodes } from "http-status-codes";
import { walletAuthSchema } from "../../../../../../core/schema";
import { queueTx } from "../../../../../../src/db/transactions/queueTx";
import {
erc1155ContractParamSchema,
standardResponseSchema,
transactionWritesResponseSchema,
} from "../../../../../helpers/sharedApiSchemas";
import { walletAuthSchema } from "../../../../../schemas/wallet";
import { txOverridesForWriteRequest } from "../../../../../schemas/web3api-overrides";
import { getChainIdFromChain } from "../../../../../utilities/chain";
import { getContract } from "../../../../../utils/cache/getContract";
Expand Down
Loading

0 comments on commit ba943ae

Please sign in to comment.