Skip to content

Commit

Permalink
Fix one problem with mod's advancements
Browse files Browse the repository at this point in the history
  • Loading branch information
neroduckale committed Apr 27, 2024
1 parent 504e7f2 commit 177bab9
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
2 changes: 1 addition & 1 deletion gradle.properties
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ yarn_mappings=1.20.1+build.10
loader_version=0.15.6

# Mod Properties
mod_version=1.2.0
mod_version=1.2.1
maven_group=ru.neroduckale
archives_base_name=nerodiscord

Expand Down
3 changes: 2 additions & 1 deletion src/main/java/ru/neroduckale/Events.java
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@
import net.minecraft.server.network.ServerPlayerEntity;

import java.awt.*;
import java.util.Objects;

import static ru.neroduckale.NeroDiscord.*;
import static ru.neroduckale.Utils.*;
Expand Down Expand Up @@ -66,7 +67,7 @@ public static void OnNewAdvancement(Advancement advancement, String nickname) {
var localedesc = localtestr + ".description";
var translatedTitle = getJson(localetitle);
var translatedDescription = getJson(localedesc);
if (translatedTitle != null && translatedDescription != null) {
if (!Objects.equals(translatedTitle, "null") && !Objects.equals(translatedDescription, "null")) {
SendEmbedNewAdvancement(translatedTitle, translatedDescription, nickname);
return;
}
Expand Down

0 comments on commit 177bab9

Please sign in to comment.