show the link only if there's a username (#8238)
parent
9d3963436b
commit
86e903ce4a
|
@ -95,7 +95,7 @@ export default function MemberListItem(props: Props) {
|
||||||
process.env.NEXT_PUBLIC_TEAM_IMPERSONATION === "true";
|
process.env.NEXT_PUBLIC_TEAM_IMPERSONATION === "true";
|
||||||
|
|
||||||
const urlWithoutProtocol = WEBAPP_URL.replace(/^https?:\/\//, "");
|
const urlWithoutProtocol = WEBAPP_URL.replace(/^https?:\/\//, "");
|
||||||
const bookingLink = `${urlWithoutProtocol}/${props.member.username}`;
|
const bookingLink = !!props.member.username && `${urlWithoutProtocol}/${props.member.username}`;
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<li className="divide-subtle divide-y px-5">
|
<li className="divide-subtle divide-y px-5">
|
||||||
|
|
Loading…
Reference in New Issue