Rename #toLegacy to #toFormat since it didn't make sense

This commit is contained in:
themode 2021-01-31 00:25:49 +01:00
parent 8f174f2c87
commit 2f326aeaae

View File

@ -69,7 +69,7 @@ public class ColoredText extends JsonMessage {
*/
@NotNull
public static ColoredText ofLegacy(@NotNull String message, char colorChar) {
final String legacy = toLegacy(message, colorChar);
final String legacy = toFormat(message, colorChar);
return of(legacy);
}
@ -107,7 +107,7 @@ public class ColoredText extends JsonMessage {
*/
@NotNull
public ColoredText appendLegacy(@NotNull String message, char colorChar) {
final String legacy = toLegacy(message, colorChar);
final String legacy = toFormat(message, colorChar);
return of(legacy);
}
@ -326,7 +326,8 @@ public class ColoredText extends JsonMessage {
* @param colorChar the char used before the color code
* @return the converted legacy text
*/
private static String toLegacy(@NotNull String message, char colorChar) {
@NotNull
private static String toFormat(@NotNull String message, char colorChar) {
StringBuilder result = new StringBuilder();
for (int i = 0; i < message.length(); i++) {