gancio-upstream/server/migrations/20191027132035-fed_users_instances.js
2019-10-30 15:01:15 +01:00

19 lines
433 B
JavaScript

'use strict'
module.exports = {
up: (queryInterface, Sequelize) => {
return queryInterface.addColumn('fed_users', 'instanceDomain', {
type: Sequelize.STRING,
references: {
model: 'instances',
key: 'domain'
},
onUpdate: 'CASCADE',
onDelete: 'CASCADE'
})
},
down: (queryInterface, Sequelize) => {
return queryInterface.removeColumn('fed_users', 'instanceDomain')
}
}