Skip to content

Commit

Permalink
Fix database
Browse files Browse the repository at this point in the history
  • Loading branch information
Zaptoss committed Jul 26, 2024
1 parent f126356 commit 36649ea
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions internal/data/pg/referrals.go
Original file line number Diff line number Diff line change
Expand Up @@ -117,8 +117,8 @@ func (q *referrals) WithStatus() data.ReferralsQ {
status = fmt.Sprintf(`CASE
WHEN infinity = TRUE THEN '%s'
WHEN usage_left > 0 THEN '%s'
WHEN rr.is_verified = FALSE AND re.is_verified = TRUE THEN '%s'
WHEN rr.is_verified = TRUE AND re.is_verified = TRUE THEN '%s'
WHEN (rr.internal_aid IS NULL AND rr.external_aid IS NULL) AND (re.internal_aid IS NOT NULL OR re.external_aid IS NOT NULL) THEN '%s'
WHEN (rr.internal_aid IS NOT NULL OR rr.external_aid IS NOT NULL) AND (re.internal_aid IS NOT NULL OR re.external_aid IS NOT NULL) THEN '%s'
ELSE '%s'
END AS status`,
data.StatusInfinity, data.StatusActive, data.StatusAwaiting,
Expand Down

0 comments on commit 36649ea

Please sign in to comment.