Skip to content

Commit

Permalink
fix
Browse files Browse the repository at this point in the history
  • Loading branch information
0xKurt committed Sep 9, 2024
1 parent 8acbedd commit a20f9ca
Show file tree
Hide file tree
Showing 3 changed files with 14 additions and 7 deletions.
2 changes: 1 addition & 1 deletion src/config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ type CoingeckoSupportedChainId =
| 42220
| 1088;

const CHAIN_DATA_VERSION = "82";
const CHAIN_DATA_VERSION = "83";
const IPFS_DATA_VERSION = "1";
const PRICE_DATA_VERSION = "1";

Expand Down
17 changes: 12 additions & 5 deletions src/database/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -994,35 +994,42 @@ export class Database {
.where("chainId", "=", chainId)
.execute();

this.#logger.info("Deleting applications payouts");
this.#logger.info("Deleting applications");
await trx
.withSchema(this.chainDataSchemaName)
.deleteFrom("applications")
.where("chainId", "=", chainId)
.execute();

this.#logger.info("Deleting applications payouts");
this.#logger.info("Deleting applications donations");
await trx
.withSchema(this.chainDataSchemaName)
.deleteFrom("donations")
.where("chainId", "=", chainId)
.execute();

this.#logger.info("Deleting applications payouts");
// this.#logger.info("Deleting donation prices");
// await trx
// .withSchema(this.priceDataSchemaName)
// .deleteFrom("prices")
// .where("chainId", "=", chainId)
// .execute();

this.#logger.info("Deleting applications");
await trx
.withSchema(this.chainDataSchemaName)
.deleteFrom("applications")
.where("chainId", "=", chainId)
.execute();

this.#logger.info("Deleting applications payouts");
this.#logger.info("Deleting rounds");
await trx
.withSchema(this.chainDataSchemaName)
.deleteFrom("rounds")
.where("chainId", "=", chainId)
.execute();

this.#logger.info("Deleting applications payouts");
this.#logger.info("Deleting projects");
await trx
.withSchema(this.chainDataSchemaName)
.deleteFrom("projects")
Expand Down
2 changes: 1 addition & 1 deletion src/http/app.ts
Original file line number Diff line number Diff line change
Expand Up @@ -173,7 +173,7 @@ export const createHttpApi = (config: HttpApiConfig): HttpApi => {
contract: contractName,
address: subscription.address,
fromBlock: subscriptionFromBlock || BigInt(0),
});
});
});
} else {
config.logger.error(
Expand Down

0 comments on commit a20f9ca

Please sign in to comment.