Null pointer translation fix
This commit is contained in:
parent
8eba063b40
commit
3efa71b08a
5 changed files with 5 additions and 5 deletions
|
@ -30,7 +30,7 @@ public class TranslationHelper {
|
|||
|
||||
Gson gson = new Gson();
|
||||
InputStream inputStream = TranslationHelper.class.getResourceAsStream("/assets/" + modID + "/lang/" + languageCode + ".json");
|
||||
JsonObject translation = gson.fromJson(new InputStreamReader(inputStream), JsonObject.class);
|
||||
JsonObject translation = inputStream == null ? new JsonObject() : gson.fromJson(new InputStreamReader(inputStream), JsonObject.class);
|
||||
|
||||
Registry.BLOCK.forEach(block -> {
|
||||
if (Registry.BLOCK.getKey(block).getNamespace().equals(modID)) {
|
||||
|
|
|
@ -1,6 +0,0 @@
|
|||
package ru.bclib.util;
|
||||
|
||||
@FunctionalInterface
|
||||
public interface TriConsumer<A, B, C> {
|
||||
void accept(A a, B b, C c);
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue