Fix rollback constraint

This commit is contained in:
Fang-Pen Lin
2025-11-07 09:18:01 -08:00
parent 9c199cdbb8
commit 3916d48ba4
@@ -169,9 +169,9 @@ export async function down(knex: Knex): Promise<void> {
// here because knex will generate a constraint name without quotes, and it will be treated as lowercased and causing problems. // here because knex will generate a constraint name without quotes, and it will be treated as lowercased and causing problems.
await knex.raw( await knex.raw(
`ALTER TABLE ?? `ALTER TABLE ??
ADD CONSTRAINT ?? CHECK (enrollmentType IN ('api', 'est')); ADD CONSTRAINT ?? CHECK (?? IN ('api', 'est'));
`, `,
[TableName.PkiCertificateProfile, OLD_ENROLLMENT_TYPE_CHECK_CONSTRAINT] [TableName.PkiCertificateProfile, OLD_ENROLLMENT_TYPE_CHECK_CONSTRAINT, "enrollmentType"]
); );
} }