grav-plugin-langswitcher
grav-plugin-langswitcher copied to clipboard
link href="alternative" being created for pages that don't exist
When a page does not have a translation available in a particular language, langswitcher can hide the link from the page.
However, a link to the non-existant page will still be included in the tag in the page header.
@angusmcb
Same issue here. As a quick fix, these two highlighed lines of code temporarily solved the issue for me:
Also, I deleted all empty lines to reduce the number of empty lines in the HTML output. It can still be optimized.