Skip to content

Commit

Permalink
fix(db): fix a corner case for DBSelectAllActiveAppLocksForSliceApps (#…
Browse files Browse the repository at this point in the history
…2191)

Ref: SRX-6XJZ61
  • Loading branch information
AminSlk authored Jan 8, 2025
1 parent 43618b4 commit fefd41f
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions pkg/db/db.go
Original file line number Diff line number Diff line change
Expand Up @@ -2542,6 +2542,9 @@ func (h *DBHandler) DBSelectAllActiveAppLocksForSliceApps(ctx context.Context, t
if tx == nil {
return nil, fmt.Errorf("DBSelectAllActiveAppLocksForSliceApps: no transaction provided")
}
if len(appNames) == 0 {
return []ApplicationLock{}, nil
}

var rows *sql.Rows
defer func(rows *sql.Rows) {
Expand Down

0 comments on commit fefd41f

Please sign in to comment.