From fab9028caa4ab8bbb305f9d8731947b3bddd78f4 Mon Sep 17 00:00:00 2001 From: Erik Jan de Wit Date: Mon, 15 Jul 2024 15:31:01 +0200 Subject: [PATCH] fixed the url missed after refactoring (#31284) fixes: #31244 Signed-off-by: Erik Jan de Wit --- .../src/identity-providers/component/RedirectUrl.tsx | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/js/apps/admin-ui/src/identity-providers/component/RedirectUrl.tsx b/js/apps/admin-ui/src/identity-providers/component/RedirectUrl.tsx index 3f110aa37f..f6e57e40a1 100644 --- a/js/apps/admin-ui/src/identity-providers/component/RedirectUrl.tsx +++ b/js/apps/admin-ui/src/identity-providers/component/RedirectUrl.tsx @@ -1,18 +1,16 @@ import { ClipboardCopy, FormGroup } from "@patternfly/react-core"; import { useTranslation } from "react-i18next"; -import { HelpItem } from "@keycloak/keycloak-ui-shared"; -import { useAdminClient } from "../../admin-client"; +import { HelpItem, useEnvironment } from "@keycloak/keycloak-ui-shared"; import { useRealm } from "../../context/realm-context/RealmContext"; import { addTrailingSlash } from "../../util"; export const RedirectUrl = ({ id }: { id: string }) => { - const { adminClient } = useAdminClient(); - + const { environment } = useEnvironment(); const { t } = useTranslation(); const { realm } = useRealm(); const callbackUrl = `${addTrailingSlash( - adminClient.baseUrl, + environment.serverBaseUrl, )}realms/${realm}/broker`; return (