# HG changeset patch # User HIROSE Yuuji # Date 1653793980 -32400 # Node ID 084326d5ba19a4800d719b87d9fe04537d97542e # Parent 71528696780b610349a28243b367960ace3cff16 FIX: JS return -1 when string-search fails... diff -r 71528696780b -r 084326d5ba19 s4-main.js --- a/s4-main.js Sun May 29 12:07:59 2022 +0900 +++ b/s4-main.js Sun May 29 12:13:00 2022 +0900 @@ -1052,7 +1052,7 @@ if (text.startsWith("\>#")) { let newline = text.indexOf("\n"); let first, rest; - if (newline) { + if (newline > 0) { first = text.substring(0, newline); rest = text.substring(newline); } else {