holy shit

https://github.com/sequelize/sequelize/issues/10360
This commit is contained in:
les 2020-01-29 18:37:52 +01:00
parent 8c0c5d08fd
commit 8bc226eb4c

View file

@ -0,0 +1,19 @@
module.exports = {
up: (queryInterface, Sequelize) => {
return queryInterface.addIndex('users', {
unique: true,
fields: ['email']
}).catch(e => {})
},
down: (queryInterface, Sequelize) => {
/*
Add reverting commands here.
Return a promise to correctly handle asynchronicity.
Example:
return queryInterface.dropTable('users');
*/
}
};