Skip to content

Commit

Permalink
Fix condition on GetPLNullOrders
Browse files Browse the repository at this point in the history
  • Loading branch information
rluisr committed Sep 28, 2022
1 parent 79bd14b commit be9e853
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion pkg/adapter/gateway/tv_repository.go
Original file line number Diff line number Diff line change
Expand Up @@ -78,6 +78,6 @@ func (r *TVRepository) SaveWalletHistories(histories []domain.WalletHistory) err

func (r *TVRepository) GetPLNullOrders(settingID uint64) (*[]domain.TVOrder, error) {
var orders []domain.TVOrder
err := r.RODB.Where("setting_id = ? AND pl IS NULL", settingID).Order("id desc").Find(&orders).Error
err := r.RODB.Where("setting_id = ? AND (pl IS NULL OR pl = 0)", settingID).Order("id desc").Find(&orders).Error
return &orders, err
}

0 comments on commit be9e853

Please sign in to comment.