From 4889e9732d2458d60e2a079d3e54e128f6ce1b53 Mon Sep 17 00:00:00 2001 From: BoHong Li Date: Wed, 8 Mar 2017 18:45:51 +0800 Subject: Use JavaScript Standard Style Introduce JavaScript Standard Style as project style rule, and fixed all fail on backend code. --- lib/migrations/20160703062241-support-authorship.js | 18 +++++++----------- 1 file changed, 7 insertions(+), 11 deletions(-) (limited to 'lib/migrations/20160703062241-support-authorship.js') diff --git a/lib/migrations/20160703062241-support-authorship.js b/lib/migrations/20160703062241-support-authorship.js index 239327ec..98381d4e 100644 --- a/lib/migrations/20160703062241-support-authorship.js +++ b/lib/migrations/20160703062241-support-authorship.js @@ -1,9 +1,7 @@ -'use strict'; - module.exports = { up: function (queryInterface, Sequelize) { - queryInterface.addColumn('Notes', 'authorship', Sequelize.TEXT); - queryInterface.addColumn('Revisions', 'authorship', Sequelize.TEXT); + queryInterface.addColumn('Notes', 'authorship', Sequelize.TEXT) + queryInterface.addColumn('Revisions', 'authorship', Sequelize.TEXT) queryInterface.createTable('Authors', { id: { type: Sequelize.INTEGER, @@ -15,14 +13,12 @@ module.exports = { userId: Sequelize.UUID, createdAt: Sequelize.DATE, updatedAt: Sequelize.DATE - }); - return; + }) }, down: function (queryInterface, Sequelize) { - queryInterface.dropTable('Authors'); - queryInterface.removeColumn('Revisions', 'authorship'); - queryInterface.removeColumn('Notes', 'authorship'); - return; + queryInterface.dropTable('Authors') + queryInterface.removeColumn('Revisions', 'authorship') + queryInterface.removeColumn('Notes', 'authorship') } -}; +} -- cgit v1.2.3