P1: service_interest || null causes SQL NULL vs empty string inconsistency #9

Open
opened 2026-05-13 20:39:37 -05:00 by null · 0 comments
Owner

Severity: P1 — High

File: server/index.js ~line 314

Problem: sanitized.service_interest || null converts empty string to null, but a whitespace-only string like " " becomes empty string after trim (not null). Behavior is inconsistent.

Impact: Data inconsistency in database — some records have NULL, some have empty string.

Fix: Use consistent null handling — always convert empty/whitespace-only strings to null.

## Severity: P1 — High **File:** server/index.js ~line 314 **Problem:** sanitized.service_interest || null converts empty string to null, but a whitespace-only string like " " becomes empty string after trim (not null). Behavior is inconsistent. **Impact:** Data inconsistency in database — some records have NULL, some have empty string. **Fix:** Use consistent null handling — always convert empty/whitespace-only strings to null.
Sign in to join this conversation.
No Label
No Milestone
No project
No Assignees
1 Participants
Notifications
Due Date
The due date is invalid or out of range. Please use the format 'yyyy-mm-dd'.

No due date set.

Dependencies

No dependencies set.

Reference: null/Queue-North-Website#9
No description provided.