diff --git a/database/migrations/1727795538823_raise_password_max_len.ts b/database/migrations/1727795538823_raise_password_max_len.ts new file mode 100644 index 00000000..83202b0a --- /dev/null +++ b/database/migrations/1727795538823_raise_password_max_len.ts @@ -0,0 +1,17 @@ +import BaseSchema from '@ioc:Adonis/Lucid/Schema'; + +export default class extends BaseSchema { + protected tableName = 'users'; + + public async up() { + this.schema.alterTable(this.tableName, table => { + table.string('password', 254).notNullable().alter(); + }); + } + + public async down() { + this.schema.alterTable(this.tableName, table => { + table.string('password', 60).notNullable().alter(); + }); + } +}