summaryrefslogtreecommitdiff
path: root/VPNAuth.Server/Migrations/20250419123149_AddUsernameFields.cs
blob: 3d649bbee51cdd6483a1231436a5eb04aa4bae78 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
using Microsoft.EntityFrameworkCore.Migrations;

#nullable disable

namespace VPNAuth.Server.Migrations
{
    /// <inheritdoc />
    public partial class AddUsernameFields : Migration
    {
        /// <inheritdoc />
        protected override void Up(MigrationBuilder migrationBuilder)
        {
            migrationBuilder.AddColumn<string>(
                name: "Username",
                table: "AuthRequests",
                type: "TEXT",
                nullable: false,
                defaultValue: "");

            migrationBuilder.AddColumn<string>(
                name: "Username",
                table: "AccessTokens",
                type: "TEXT",
                nullable: false,
                defaultValue: "");
        }

        /// <inheritdoc />
        protected override void Down(MigrationBuilder migrationBuilder)
        {
            migrationBuilder.DropColumn(
                name: "Username",
                table: "AuthRequests");

            migrationBuilder.DropColumn(
                name: "Username",
                table: "AccessTokens");
        }
    }
}