[backend/database] Remove length restriction from DriveFile comment column
This commit is contained in:
parent
45d08caa94
commit
8c015815bc
3 changed files with 6002 additions and 2 deletions
File diff suppressed because it is too large
Load diff
|
@ -0,0 +1,42 @@
|
|||
using Microsoft.EntityFrameworkCore.Migrations;
|
||||
|
||||
#nullable disable
|
||||
|
||||
namespace Iceshrimp.Backend.Core.Database.Migrations
|
||||
{
|
||||
/// <inheritdoc />
|
||||
public partial class RemoveDriveFileCommentLengthRestriction : Migration
|
||||
{
|
||||
/// <inheritdoc />
|
||||
protected override void Up(MigrationBuilder migrationBuilder)
|
||||
{
|
||||
migrationBuilder.AlterColumn<string>(
|
||||
name: "comment",
|
||||
table: "drive_file",
|
||||
type: "text",
|
||||
nullable: true,
|
||||
comment: "The comment of the DriveFile.",
|
||||
oldClrType: typeof(string),
|
||||
oldType: "character varying(8192)",
|
||||
oldMaxLength: 8192,
|
||||
oldNullable: true,
|
||||
oldComment: "The comment of the DriveFile.");
|
||||
}
|
||||
|
||||
/// <inheritdoc />
|
||||
protected override void Down(MigrationBuilder migrationBuilder)
|
||||
{
|
||||
migrationBuilder.AlterColumn<string>(
|
||||
name: "comment",
|
||||
table: "drive_file",
|
||||
type: "character varying(8192)",
|
||||
maxLength: 8192,
|
||||
nullable: true,
|
||||
comment: "The comment of the DriveFile.",
|
||||
oldClrType: typeof(string),
|
||||
oldType: "text",
|
||||
oldNullable: true,
|
||||
oldComment: "The comment of the DriveFile.");
|
||||
}
|
||||
}
|
||||
}
|
|
@ -854,8 +854,7 @@ namespace Iceshrimp.Backend.Core.Database.Migrations
|
|||
.HasComment("The BlurHash string.");
|
||||
|
||||
b.Property<string>("Comment")
|
||||
.HasMaxLength(8192)
|
||||
.HasColumnType("character varying(8192)")
|
||||
.HasColumnType("text")
|
||||
.HasColumnName("comment")
|
||||
.HasComment("The comment of the DriveFile.");
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue