canonical / identity-platform-admin-ui

Admin UI for the Canonical identity broker and identity provider solution
Other
6 stars 4 forks source link

Fix pagination token generation to remove "old" pages #238

Closed BarcoMasile closed 6 months ago

BarcoMasile commented 6 months ago

Description

When settting tokens for new paginated response, we also need to delete pageTokens that don't have a following page, otherwise the last token for a page would always be present and the PaginationHeader method would never find the exiting condition to return "".

Example: pkg/groups/handlers.go

  for apiType, token := range pageTokens {
    paginator.SetToken(r.Context(), apiType, token)
  }

Old tokens would remain in the paginator and still end up in the base64 digest.

syncronize-issues-to-jira[bot] commented 6 months ago

Thank you for reporting us your feedback!

The internal ticket has been created: https://warthogs.atlassian.net/browse/IAM-768.

This message was autogenerated