fix exception when user does not have view-realm role (#24036)
Closes #23954
This commit is contained in:
parent
fefe2f57ae
commit
03a8f05d14
1 changed files with 2 additions and 1 deletions
|
@ -35,10 +35,11 @@ export const FederatedUserLink = ({ user }: FederatedUserLinkProps) => {
|
||||||
|
|
||||||
if (!component) return null;
|
if (!component) return null;
|
||||||
|
|
||||||
|
if (!access.hasAccess("view-realm")) return <span>{component.name}</span>;
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<Button
|
<Button
|
||||||
variant="link"
|
variant="link"
|
||||||
isDisabled={!access.hasAccess("view-realm")}
|
|
||||||
component={(props) => (
|
component={(props) => (
|
||||||
<Link
|
<Link
|
||||||
{...props}
|
{...props}
|
||||||
|
|
Loading…
Reference in a new issue