text: '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.createTable('Slates', {
        // from the contract
        slateID: {
          type: Sequelize.INTEGER,
          allowNull: false,
          primaryKey: true,
        },
        // from the contract
        metadataHash: {
          type: Sequelize.STRING,
          allowNull: false,
        },
        email: {
          type: Sequelize.STRING,
          allowNull: true,
        },
        // has this recommender had its identity verified?
        verifiedRecommender: {
          type: Sequelize.BOOLEAN,
          allowNull: false,
          defaultValue: false,
        },
        createdAt: {
          type: Sequelize.DATE,
          allowNull: false,
        },
        updatedAt: {
          type: Sequelize.DATE,
          allowNull: false,
        },
      });
    },
  
    down: (queryInterface, Sequelize) => {
      /*
        Add reverting commands here.
        Return a promise to correctly handle asynchronicity.
  
        Example:
        return queryInterface.dropTable('users');
      */
      return queryInterface.dropTable('Slates');
    },
  };
  