mirror of
https://github.com/bitwarden/server.git
synced 2026-02-02 15:13:19 +08:00
37 lines
956 B
C#
37 lines
956 B
C#
|
|
using Microsoft.EntityFrameworkCore.Migrations;
|
|||
|
|
|
|||
|
|
#nullable disable
|
|||
|
|
|
|||
|
|
namespace Bit.PostgresMigrations.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: "character varying(128)",
|
|||
|
|
maxLength: 128,
|
|||
|
|
nullable: true);
|
|||
|
|
}
|
|||
|
|
|
|||
|
|
protected override void Down(MigrationBuilder migrationBuilder)
|
|||
|
|
{
|
|||
|
|
migrationBuilder.DropColumn(
|
|||
|
|
name: "ClientSecretHash",
|
|||
|
|
table: "ApiKey");
|
|||
|
|
|
|||
|
|
migrationBuilder.AddColumn<string>(
|
|||
|
|
name: "ClientSecret",
|
|||
|
|
table: "ApiKey",
|
|||
|
|
type: "character varying(30)",
|
|||
|
|
maxLength: 30,
|
|||
|
|
nullable: true);
|
|||
|
|
}
|
|||
|
|
}
|