mirror of
https://github.com/bitwarden/server.git
synced 2024-11-22 12:15:36 +01:00
39 lines
1.0 KiB
C#
39 lines
1.0 KiB
C#
|
using Microsoft.EntityFrameworkCore.Migrations;
|
|||
|
|
|||
|
#nullable disable
|
|||
|
|
|||
|
namespace Bit.MySqlMigrations.Migrations;
|
|||
|
|
|||
|
public partial class ClientSecretHash : Migration
|
|||
|
{
|
|||
|
protected override void Up(MigrationBuilder migrationBuilder)
|
|||
|
{
|
|||
|
migrationBuilder.DropColumn(
|
|||
|
name: "ClientSecret",
|
|||
|
table: "ApiKey");
|
|||
|
|
|||
|
migrationBuilder.AddColumn<string>(
|
|||
|
name: "ClientSecretHash",
|
|||
|
table: "ApiKey",
|
|||
|
type: "varchar(128)",
|
|||
|
maxLength: 128,
|
|||
|
nullable: true)
|
|||
|
.Annotation("MySql:CharSet", "utf8mb4");
|
|||
|
}
|
|||
|
|
|||
|
protected override void Down(MigrationBuilder migrationBuilder)
|
|||
|
{
|
|||
|
migrationBuilder.DropColumn(
|
|||
|
name: "ClientSecretHash",
|
|||
|
table: "ApiKey");
|
|||
|
|
|||
|
migrationBuilder.AddColumn<string>(
|
|||
|
name: "ClientSecret",
|
|||
|
table: "ApiKey",
|
|||
|
type: "varchar(30)",
|
|||
|
maxLength: 30,
|
|||
|
nullable: true)
|
|||
|
.Annotation("MySql:CharSet", "utf8mb4");
|
|||
|
}
|
|||
|
}
|