merge: Increase character hard limits (resolves #686 and #696) (!647)

View MR for information: https://activitypub.software/TransFem-org/Sharkey/-/merge_requests/647

Closes #686 and #696

Approved-by: Marie <github@yuugi.dev>
Approved-by: dakkar <dakkar@thenautilus.net>
This commit is contained in:
Hazelnoot 2024-10-07 23:20:14 +00:00
commit a90b4d487a
11 changed files with 57 additions and 10 deletions

View file

@ -4,6 +4,7 @@
*/
import { PrimaryColumn, Entity, Index, JoinColumn, Column, ManyToOne } from 'typeorm';
import { DB_MAX_IMAGE_COMMENT_LENGTH } from '@/const.js';
import { id } from './util/id.js';
import { MiUser } from './User.js';
import { MiDriveFolder } from './DriveFolder.js';
@ -61,7 +62,7 @@ export class MiDriveFile {
public size: number;
@Column('varchar', {
length: 8192,
length: DB_MAX_IMAGE_COMMENT_LENGTH,
nullable: true,
comment: 'The comment of the DriveFile.',
})

View file

@ -66,8 +66,8 @@ export class MiNote {
})
public name: string | null;
@Column('varchar', {
length: 512, nullable: true,
@Column('text', {
nullable: true,
})
public cw: string | null;