diff --git a/migration/1582875306439-note-reaction-length.ts b/migration/1582875306439-note-reaction-length.ts new file mode 100644 index 000000000..b9af61eb0 --- /dev/null +++ b/migration/1582875306439-note-reaction-length.ts @@ -0,0 +1,14 @@ +import {MigrationInterface, QueryRunner} from "typeorm"; + +export class noteReactionLength1582875306439 implements MigrationInterface { + name = 'noteReactionLength1582875306439' + + public async up(queryRunner: QueryRunner): Promise { + await queryRunner.query(`ALTER TABLE "note_reaction" ALTER COLUMN "reaction" TYPE character varying(130)`, undefined); + } + + public async down(queryRunner: QueryRunner): Promise { + await queryRunner.query(`ALTER TABLE "note_reaction" ALTER COLUMN "reaction" TYPE character varying(128)`, undefined); + } + +} diff --git a/src/models/entities/note-reaction.ts b/src/models/entities/note-reaction.ts index a958e8957..995748760 100644 --- a/src/models/entities/note-reaction.ts +++ b/src/models/entities/note-reaction.ts @@ -36,7 +36,7 @@ export class NoteReaction { public note: Note | null; @Column('varchar', { - length: 128 + length: 130 }) public reaction: string; }