Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- 'use strict';
- var fs = require('fs');
- module.exports = {
- up: function (queryInterface, Sequelize, done) {
- return fs.readFile('./node_modules/pg-job-queue/lib/schema.sql', 'utf-8', function (err, data) {
- return queryInterface.sequelize.query(data)
- .then(function (response) {
- done();
- }).catch(function (err) {
- done();
- });
- });
- },
- down: function (queryInterface, Sequelize, done) {
- /*
- Add reverting commands here.
- Return a promise to correctly handle asynchronicity.
- Example:
- return queryInterface.dropTable('users');
- */
- return queryInterface.dropTable('JobQueue');
- }
- };
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement