diff --git a/src/main/java/org/crosswire/jsword/versification/BibleNames.java b/src/main/java/org/crosswire/jsword/versification/BibleNames.java index 10574b61c..365835b02 100644 --- a/src/main/java/org/crosswire/jsword/versification/BibleNames.java +++ b/src/main/java/org/crosswire/jsword/versification/BibleNames.java @@ -25,6 +25,7 @@ import java.util.Map; import java.util.MissingResourceException; import java.util.ResourceBundle; +import java.util.regex.Pattern; import org.crosswire.common.util.CWClassLoader; import org.crosswire.common.util.ClassUtil; @@ -39,6 +40,7 @@ * @author DM Smith */ public final class BibleNames { + public static final Pattern dashPattern = Pattern.compile("\\s*-\\s*"); /** * Get the singleton instance of BibleNames. * @@ -414,7 +416,7 @@ private void store(ResourceBundle resources, BibleBook book, Map fullMap, Map sh } String altBook = getString(resources, osisName + ALT_KEY); - if(altBook != null && altBook.strip().equals("-")) { + if(altBook == null || dashPattern.matcher(altBook).matches()) { altBook = ""; }