API: trackers: fix cursor

This commit is contained in:
Drew DeVault 2021-03-22 12:31:45 -04:00
parent fc40d2a18e
commit c69656bbe2
1 changed files with 1 additions and 1 deletions

View File

@ -85,7 +85,7 @@ func (t *Tracker) QueryWithCursor(ctx context.Context, runner sq.BaseRunner,
}
auser := auth.ForContext(ctx)
q = q.
OrderBy(database.WithAlias(t.alias, "id")).
OrderBy(database.WithAlias(t.alias, "id") + " DESC").
Limit(uint64(cur.Count + 1)).
LeftJoin(`user_access tr_ua ON tr_ua.tracker_id = tr.id`).
Column(`COALESCE(