Skip to content

[KEYCLOAK-16792] Pass realm instead of ID to Get Realm Localization Texts method - #7707

Closed
johngrimes wants to merge 1 commit into
keycloak:masterfrom
johngrimes:patch-1
Closed

johngrimes wants to merge 1 commit into
keycloak:masterfrom
johngrimes:patch-1

Conversation

@johngrimes

Copy link
Copy Markdown

The realm controller within the UI for the security admin console is incorrectly sending through the id of the realm, rather than the realm attribute, when calling the "Get Realm Localization Texts" API method on the admin REST API.

This is causing 404 errors in cases where there is a realm with an id that is different to the realm.

Here is the documentation for Get Realm Localization Texts: https://www.keycloak.org/docs-api/12.0/rest-api/index.html#_getrealmlocalizationtexts

@hmlnarik
hmlnarik requested a review from ssilvert January 12, 2021 17:14
@hmlnarik hmlnarik added area/ui kind/bug Categorizes a PR related to a bug labels Jan 12, 2021
@hmlnarik

Copy link
Copy Markdown
Contributor

@johngrimes Thank you for the PR. Could you please introduce a JIRA and ensure that the JIRA is referenced both in PR title and the commit message.

@johngrimes johngrimes changed the title Pass realm instead of ID to Get Realm Localization Texts method [KEYCLOAK-16792] Pass realm instead of ID to Get Realm Localization Texts method Jan 12, 2021
@johngrimes

Copy link
Copy Markdown
Author

@hmlnarik Ok, I have created a JIRA issue and renamed the commit.

@pedroigor

Copy link
Copy Markdown
Contributor

@johngrimes Thanks for the PR. It was just fixed by #7724.

In summary, the Current.realm.name should always be used (as in other places) to actually use the realm name in URLs. The name should always be there, so it should be safe to always pass it over.

@pedroigor pedroigor closed this Jan 29, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

kind/bug Categorizes a PR related to a bug

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants