mirror of
https://github.com/naturalcrit/homebrewery.git
synced 2026-11-23 23:06:54 +00:00
Add guard clause to prevent empty nav lines
This commit is contained in:
1 parent
914521cada
commit
9c2610ff40
1 file changed
+2
@@ -71,6 +71,8 @@ const HeaderNavItem = ({ link, text, depth, className })=>{
|
||||
return output;
|
||||
};
|
||||
|
||||
if(!link || !text) return;
|
||||
|
||||
return <li>
|
||||
<a href={`#${link}`} target='_self' className={`depth-${depth} ${className ?? ''}`}>
|
||||
{trimString(text, depth)}
|
||||
|
||||
Reference in new issue
Block a user