diff --git a/backend/src/database/migrations/20240812063204-add-user-id-index-to-email-messages-transactional.js b/backend/src/database/migrations/20240812063204-add-user-id-index-to-email-messages-transactional.js index 95faeb7ab..64e8910d5 100644 --- a/backend/src/database/migrations/20240812063204-add-user-id-index-to-email-messages-transactional.js +++ b/backend/src/database/migrations/20240812063204-add-user-id-index-to-email-messages-transactional.js @@ -3,12 +3,12 @@ module.exports = { up: async (queryInterface, Sequelize) => { await queryInterface.addIndex('email_messages_transactional', { - name: 'email_messages_transactional_user_id_idx', - fields: ['user_id'] + name: 'email_messages_transactional_user_id_tag_idx', + fields: ['user_id', 'tag'] }) }, down: async (queryInterface, Sequelize) => { - await queryInterface.removeIndex('email_messages_transactional', 'email_messages_transactional_user_id_idx') + await queryInterface.removeIndex('email_messages_transactional', 'email_messages_transactional_user_id_tag_idx') } };