diff --git a/packages/api/db/migration/20250203144322_add_base_properties_to_farm_addon.js b/packages/api/db/migration/20250203144322_add_base_properties_to_farm_addon.js index 1f3e8a7291..006985bc8b 100644 --- a/packages/api/db/migration/20250203144322_add_base_properties_to_farm_addon.js +++ b/packages/api/db/migration/20250203144322_add_base_properties_to_farm_addon.js @@ -15,7 +15,7 @@ export const up = async function (knex) { await knex.schema.alterTable('farm_addon', (t) => { - // Knex apparently does not rename indexes aliong with table names + // Knex apparently does not rename indexes along with table names t.dropPrimary('farm_external_integration_pkey'); }); await knex.schema.alterTable('farm_addon', (t) => { @@ -48,6 +48,7 @@ export const up = async function (knex) { }; export const down = async function (knex) { + await knex('farm_addon').where({ deleted: true }).del(); await knex.schema.alterTable('farm_addon', (t) => { t.dropIndex(['farm_id', 'addon_partner_id'], 'farm_addon_uniqueness_composite'); t.dropPrimary();