Skip to content

Commit

Permalink
Check for empty strings
Browse files Browse the repository at this point in the history
  • Loading branch information
Perlkonig committed Sep 15, 2024
1 parent d33a962 commit 5ecc5dc
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/components/Player.js
Original file line number Diff line number Diff line change
Expand Up @@ -197,7 +197,7 @@ function Player() {
</>
)}
<ActivityMarker lastSeen={user.lastSeen} />
{user.bggid === undefined ? null : (
{user.bggid === undefined || /^\s*$/.test(user.bggid) ? null : (
<span style={{ fontSize: "smaller", marginLeft: "1em" }}>
<a
href={`https://boardgamegeek.com/user/${user.bggid}`}
Expand All @@ -209,7 +209,7 @@ function Player() {
</span>
)}
</div>
{user.about === undefined ? null : (
{user.about === undefined || /^\s*$/.test(user.about) ? null : (
<ReactMarkdown
remarkPlugins={[remarkGfm]}
rehypePlugins={[rehypeRaw]}
Expand Down

0 comments on commit 5ecc5dc

Please sign in to comment.