Skip to content

Commit

Permalink
Fix pagination in provider list
Browse files Browse the repository at this point in the history
Signed-off-by: Juan Antonio Osorio <[email protected]>
  • Loading branch information
JAORMX committed Mar 26, 2024
1 parent 8fa031d commit 9da9b28
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion internal/controlplane/handlers_providers.go
Original file line number Diff line number Diff line change
Expand Up @@ -138,7 +138,7 @@ func (s *Server) ListProviders(ctx context.Context, req *minderv1.ListProvidersR
}

cursor := ""
if len(list) > 0 {
if len(list) > 0 && len(list) == int(params.Limit) {
c := cursorutil.ProviderCursor{
CreatedAt: list[len(list)-1].CreatedAt,
}
Expand Down

0 comments on commit 9da9b28

Please sign in to comment.