review fixes

This commit is contained in:
x
2025-04-30 22:24:26 -04:00
parent bbfd4a44c3
commit 580de0565b
4 changed files with 46 additions and 29 deletions
@@ -4,11 +4,6 @@ import { TableName } from "../schemas";
export async function up(knex: Knex): Promise<void> {
if (await knex.schema.hasTable(TableName.Certificate)) {
await knex.schema.alterTable(TableName.Certificate, (t) => {
t.uuid("caId").nullable().alter();
t.uuid("caCertId").nullable().alter();
});
const hasProjectIdColumn = await knex.schema.hasColumn(TableName.Certificate, "projectId");
if (!hasProjectIdColumn) {
await knex.transaction(async (trx) => {
@@ -29,6 +24,11 @@ export async function up(knex: Knex): Promise<void> {
});
});
}
await knex.schema.alterTable(TableName.Certificate, (t) => {
t.uuid("caId").nullable().alter();
t.uuid("caCertId").nullable().alter();
});
}
}