Files
chat/internal/handlers/api.go
user 25cbbfd42a
All checks were successful
check / check (push) Successful in 2m17s
Replace string-matching error detection with typed SQLite errors
Use errors.As with *sqlite.Error and SQLITE_CONSTRAINT_UNIQUE code
instead of fragile strings.Contains(err.Error(), "UNIQUE") checks.

Add db.IsUniqueConstraintError helper in internal/db/errors.go and
replace all three string-matching call sites in api.go and auth.go.
2026-03-10 03:18:33 -07:00

47 KiB