From: Niki Roo Date: Tue, 26 May 2020 19:36:10 +0000 (+0200) Subject: update from master X-Git-Url: https://git.nikiroo.be/?a=commitdiff_plain;h=a72efc14cd0ce75cd67f434435eecabc7ff8fb17;p=fanfix.git update from master --- diff --git a/supported/Text.java b/supported/Text.java index 252aca0..45d970a 100644 --- a/supported/Text.java +++ b/supported/Text.java @@ -227,9 +227,12 @@ class Text extends BasicSupport { @SuppressWarnings("resource") // cannot close, or we loose getInput()! Scanner scan = new Scanner(getInput(), "UTF-8"); scan.useDelimiter("\\n"); - scan.next(); // title - scan.next(); // author - scan.next(); // date or empty + if (scan.hasNext()) + scan.next(); // title + if (scan.hasNext()) + scan.next(); // author + if (scan.hasNext()) + scan.next(); // date or empty Boolean inChap = null; String line = ""; while (scan.hasNext()) {