text fixes

This commit is contained in:
Evan Kranzler 2021-04-22 08:41:54 -04:00
parent d37b760167
commit f7340a946e
10 changed files with 42 additions and 64 deletions

View file

@ -912,7 +912,10 @@ public final class CardUtil {
}
public static String addArticle(String text) {
if (text.startsWith("a ") || text.startsWith("an ")) {
if (text.startsWith("a ")
|| text.startsWith("an ")
|| text.startsWith("another ")
|| text.startsWith("any ")) {
return text;
}
return "aeiou".contains("" + text.charAt(0)) ? "an " + text : "a " + text;