feat: account deletion; auto incremental uids; display name renaming UI + account deletion UI; enhanced username validation

This commit is contained in:
2026-01-04 16:58:05 -05:00
parent b1d2d3f5bb
commit fe54ff15ce
18 changed files with 972 additions and 51 deletions
+13
View File
@@ -111,6 +111,19 @@ namespace SharpbinV3.Server
{
var db = scope.ServiceProvider.GetRequiredService<AppDbContext>();
db.Database.Migrate();
// this is temporary since the migration doesnt seem to work properly
db.Database.ExecuteSql($"""
CREATE TRIGGER IF NOT EXISTS Users_UID_AutoIncrement
AFTER INSERT ON Users
BEGIN
UPDATE Users
SET UID = (
SELECT IFNULL(MAX(UID), 0) + 1 FROM Users
)
WHERE rowid = NEW.rowid AND NEW.UID IS NULL;
END;
""");
}
app.MapHealthChecks("/health");