Skip to content

Commit

Permalink
Support null titles in report
Browse files Browse the repository at this point in the history
  • Loading branch information
blakemcbride committed Aug 18, 2024
1 parent 555b3f0 commit b5636c3
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions src/main/core/org/kissweb/Groff.java
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ private Groff() {}
* On the front-end side, see JavaScript Utils.showReport()
*
* @param fnamePrefix final PDF file name prefix
* @param title report title
* @param title report title or null
* @param landscape true if landscape format, portrait otherwise
* @throws IOException
*/
Expand Down Expand Up @@ -377,7 +377,8 @@ private void writePageHeader(String title) {
else if (!runDate.isEmpty())
pw.println("'tl '''" + runDate + "'");
pw.println("'ce " + (1 + pageTitleLines.size()));
pw.println(title);
if (title != null && !title.isEmpty())
pw.println(title);
for (String line : pageTitleLines)
pw.println(line);
pw.println("'SP");
Expand Down

0 comments on commit b5636c3

Please sign in to comment.