I've a documentclass myclass that's based on KOMA-script's scrartcl class.
MWE: myclass.cls
\NeedsTeXFormat{LaTeX2e}
% The document class name
\ProvidesClass{myclass}
% https://tex.stackexchange.com/a/121829
\DeclareOption*{\PassOptionsToClass{\CurrentOption}{scrartcl}}
\ProcessOptions\relax
\PassOptionsToPackage{headlines=3}{typearea}
% The document class to base this class on
\LoadClass{scrartcl}
\RequirePackage[headsepline]{scrlayer-scrpage}
% The page headers
\lohead{\csname @author\endcsname\Foo\Bar}
How do I conditionally insert \csname @author\endcsname\\ in the beginning of lohead iff the argument to the command* \author{} is non-empty? The issue is that currently a newline is always inserted into the header.
* Unsure of the terminology here.