text: don't remove double spaces in toJagexName

This commit is contained in:
Cyborger1
2021-08-16 10:40:05 -04:00
committed by GitHub
parent 06b6f845e8
commit bd762cc0da
2 changed files with 18 additions and 1 deletions

View File

@@ -130,7 +130,7 @@ public class Text
*/
public static String toJagexName(String str)
{
return CharMatcher.ascii().retainFrom(str.replace('\u00A0', ' ')).replaceAll("[_-]+", " ").trim();
return CharMatcher.ascii().retainFrom(str.replaceAll("[\u00A0_-]", " ")).trim();
}
/**