feat: password resets

fix: frontend docker file
chore: format via csharpier again
This commit is contained in:
2026-06-18 21:15:34 -04:00
parent 67ccee736a
commit d4976ac9aa
34 changed files with 3236 additions and 26 deletions
@@ -0,0 +1,45 @@
using Microsoft.EntityFrameworkCore.Migrations;
#nullable disable
namespace SharpbinV3.Server.Migrations
{
/// <inheritdoc />
public partial class uniqueEmails : Migration
{
/// <inheritdoc />
protected override void Up(MigrationBuilder migrationBuilder)
{
migrationBuilder.Sql(
"""
UPDATE "Users"
SET "Email" = NULL, "EmailVerified" = 0
WHERE "Email" IS NULL OR trim("Email") = '';
"""
);
migrationBuilder.Sql(
"""
UPDATE "Users"
SET "Email" = lower(trim("Email"))
WHERE "Email" IS NOT NULL;
"""
);
migrationBuilder.CreateIndex(
name: "IX_Users_Email",
table: "Users",
column: "Email",
unique: true,
filter: "\"Email\" IS NOT NULL");
}
/// <inheritdoc />
protected override void Down(MigrationBuilder migrationBuilder)
{
migrationBuilder.DropIndex(
name: "IX_Users_Email",
table: "Users");
}
}
}