Built motion from commit 1333b3551.|1.0.38
[motion.git] / server / migrations / 20160404155902-motion.js
1 'use strict';
2
3 module.exports = {
4   up: function(queryInterface, Sequelize) {
5     /*
6       Add altering commands here.
7       Return a promise to correctly handle asynchronicity.
8
9       Example:
10       return queryInterface.createTable('users', { id: Sequelize.INTEGER });
11     */
12     queryInterface.addIndex('dashboards', ['name'], {
13       unique: true,
14       indicesType: 'UNIQUE',
15       indexName: 'name'
16     });
17   },
18
19   down: function(queryInterface, Sequelize) {
20     /*
21       Add reverting commands here.
22       Return a promise to correctly handle asynchronicity.
23
24       Example:
25       return queryInterface.dropTable('users');
26     */
27     queryInterface.removeIndex('dashboards', 'name');
28   }
29 };