aboutsummaryrefslogtreecommitdiffstats
path: root/database
diff options
context:
space:
mode:
Diffstat (limited to 'database')
-rw-r--r--database/migrations/1612629845398_users_update_schema.js26
1 files changed, 12 insertions, 14 deletions
diff --git a/database/migrations/1612629845398_users_update_schema.js b/database/migrations/1612629845398_users_update_schema.js
index d07f66d..10b82aa 100644
--- a/database/migrations/1612629845398_users_update_schema.js
+++ b/database/migrations/1612629845398_users_update_schema.js
@@ -1,20 +1,18 @@
1'use strict'
2
3/** @type {import('@adonisjs/lucid/src/Schema')} */ 1/** @type {import('@adonisjs/lucid/src/Schema')} */
4const Schema = use('Schema') 2const Schema = use('Schema');
5 3
6class UsersUpdateSchema extends Schema { 4class UsersUpdateSchema extends Schema {
7 up() { 5 up() {
8 this.table('users', (table) => { 6 this.table('users', (table) => {
9 table.string('lastname', 80).notNullable().default(''); 7 table.string('lastname', 80).notNullable().default('');
10 }) 8 });
11 } 9 }
12 10
13 down() { 11 down() {
14 this.table('users', (table) => { 12 this.table('users', (table) => {
15 table.dropColumn('lastname') 13 table.dropColumn('lastname');
16 }) 14 });
17 } 15 }
18} 16}
19 17
20module.exports = UsersUpdateSchema \ No newline at end of file 18module.exports = UsersUpdateSchema;