fix database type of chat_message.text
This commit is contained in:
parent
dc1416d5d8
commit
e78c4d99f6
2 changed files with 18 additions and 2 deletions
|
|
@ -0,0 +1,16 @@
|
|||
/*
|
||||
* SPDX-FileCopyrightText: hazelnoot and other Sharkey contributors
|
||||
* SPDX-License-Identifier: AGPL-3.0-only
|
||||
*/
|
||||
|
||||
export class ChangeChatMessageTextType1753574755478 {
|
||||
name = 'ChangeChatMessageTextType1753574755478'
|
||||
|
||||
async up(queryRunner) {
|
||||
await queryRunner.query(`ALTER TABLE "chat_message" ALTER COLUMN "text" TYPE text`);
|
||||
}
|
||||
|
||||
async down(queryRunner) {
|
||||
await queryRunner.query(`ALTER TABLE "chat_message" ALTER COLUMN "text" TYPE varchar(4096)`);
|
||||
}
|
||||
}
|
||||
|
|
@ -50,8 +50,8 @@ export class MiChatMessage {
|
|||
@JoinColumn()
|
||||
public toRoom: MiChatRoom | null;
|
||||
|
||||
@Column('varchar', {
|
||||
length: 4096, nullable: true,
|
||||
@Column('text', {
|
||||
nullable: true,
|
||||
})
|
||||
public text: string | null;
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue