Skip to content

Commit

Permalink
fix(queries.Ranklist): fetch data with Find
Browse files Browse the repository at this point in the history
  • Loading branch information
Prince213 committed May 22, 2024
1 parent ea1ae15 commit babc0cf
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion pkg/queries/reward.go
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ func Ranklist(db *gorm.DB) ([]models.RanklistResponse, error) {
Select("nick_name", "reward", "is_anonymous").
Order("reward DESC").
Limit(30).
Scan(&ranklist)
Find(&ranklist)

for i := range ranklist {
if ranklist[i].IsAnonymous {
Expand Down

0 comments on commit babc0cf

Please sign in to comment.