Replace peplaceAll with replace

It does the same thing if the first argument is not a regex.
This commit is contained in:
tastybento 2022-03-19 14:29:54 +00:00
parent 3ba6620e73
commit bda56763a8
2 changed files with 2 additions and 2 deletions

View File

@ -452,7 +452,7 @@ public class YamlDatabaseHandler<T> extends AbstractDatabaseHandler<T> {
for (Entry<Object, Object> object : value.entrySet()) { for (Entry<Object, Object> object : value.entrySet()) {
// Serialize all key and values // Serialize all key and values
String key = (String)serialize(object.getKey()); String key = (String)serialize(object.getKey());
key = key.replaceAll("\\.", ":dot:"); key = key.replace("\\.", ":dot:");
result.put(key, serialize(object.getValue())); result.put(key, serialize(object.getValue()));
} }
// Save the list in the config file // Save the list in the config file

View File

@ -196,7 +196,7 @@ public class WebManager {
@NonNull @NonNull
private String getContent(@NonNull GitHubRepository repo, String fileName) { private String getContent(@NonNull GitHubRepository repo, String fileName) {
try { try {
String content = repo.getContent(fileName).getContent().replaceAll("\\n", ""); String content = repo.getContent(fileName).getContent().replace("\\n", "");
return new String(Base64.getDecoder().decode(content), StandardCharsets.UTF_8); return new String(Base64.getDecoder().decode(content), StandardCharsets.UTF_8);
} catch (IllegalAccessException e) { } catch (IllegalAccessException e) {
// Fail silently // Fail silently