1 parent 8a25c4b commit 2d0669fCopy full SHA for 2d0669f
1 file changed
src/main/java/xyz/imcodist/quickmenu/data/ActionButtonData.java
@@ -36,6 +36,10 @@ public ActionButtonDataJSON toJSON() {
36
jsonData.keybind = keybind;
37
38
actions.forEach((action) -> {
39
+ if(action == null)
40
+ {
41
+ return;
42
+ }
43
ArrayList<String> actionArray = new ArrayList<>();
44
actionArray.add(action.getJsonType());
45
actionArray.add(action.getJsonValue());
@@ -69,7 +73,9 @@ public static ActionButtonData fromJSON(ActionButtonDataJSON json) {
69
73
70
74
json.actions.forEach((actionArray) -> {
71
75
BaseActionData actionData = getActionDataType(actionArray.get(0), actionArray.get(1));
72
- data.actions.add(actionData);
76
+ if(actionData != null) {
77
+ data.actions.add(actionData);
78
79
});
80
81
if (json.icon != null) {
0 commit comments