sequelize add not null constraint
module.exports = {
up: (queryInterface, Sequelize) => {
return queryInterface.changeColumn('users', 'active', {
type: Sequelize.BOOLEAN,
allowNull: false,
defaultValue: false,
})
},
down: (queryInterface, Sequelize) => {
return queryInterface.changeColumn('users', 'active', {
type: Sequelize.BOOLEAN,
});
}
};