app/db/migrations/20200611193223-add-index-to-streets.cjs
'use strict'
module.exports = {
up: (queryInterface, Sequelize) => {
/*
Add altering commands here.
Return a promise to correctly handle asynchronicity.
Example:
return queryInterface.createTable('users', { id: Sequelize.INTEGER });
*/
return queryInterface.addIndex('Streets', ['namespaced_id', 'creator_id'])
},
down: (queryInterface, Sequelize) => {
/*
Add reverting commands here.
Return a promise to correctly handle asynchronicity.
Example:
return queryInterface.dropTable('users');
*/
queryInterface.removeIndex('Streets', ['namespaced_id', 'creator_id'])
}
}