aboutsummaryrefslogtreecommitdiff
path: root/src/main
diff options
context:
space:
mode:
authorNopoTheGamer <40329022+NopoTheGamer@users.noreply.github.com>2024-04-16 20:58:37 +1000
committerGitHub <noreply@github.com>2024-04-16 12:58:37 +0200
commit0f78d8bb772092af1d2bd9d4d38e53eba6d0fa41 (patch)
treed0539740d7f487b8ee0c4d86535d59b2f099208f /src/main
parentf66e2a5667a56c6f1a3145640b9f913f3edb6ef2 (diff)
downloadNotEnoughUpdates-0f78d8bb772092af1d2bd9d4d38e53eba6d0fa41.tar.gz
NotEnoughUpdates-0f78d8bb772092af1d2bd9d4d38e53eba6d0fa41.tar.bz2
NotEnoughUpdates-0f78d8bb772092af1d2bd9d4d38e53eba6d0fa41.zip
Fix crash with null item with dynamic lights (#1101)
Diffstat (limited to 'src/main')
-rw-r--r--src/main/kotlin/io/github/moulberry/notenoughupdates/miscgui/DynamicLightItemsEditor.kt2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/main/kotlin/io/github/moulberry/notenoughupdates/miscgui/DynamicLightItemsEditor.kt b/src/main/kotlin/io/github/moulberry/notenoughupdates/miscgui/DynamicLightItemsEditor.kt
index 6e6ec662..268bd875 100644
--- a/src/main/kotlin/io/github/moulberry/notenoughupdates/miscgui/DynamicLightItemsEditor.kt
+++ b/src/main/kotlin/io/github/moulberry/notenoughupdates/miscgui/DynamicLightItemsEditor.kt
@@ -267,7 +267,7 @@ class DynamicLightItemsEditor() : GuiScreen() {
.resolveInternalName()
if (internalName == null) {
// If resolving internal name failed, the item may be a minecraft item
- internalName = itemStack.item.registryName
+ internalName = itemStack.item?.registryName
if (internalName == null) {
// Check if minecraft searching also fails
// Leave error handling for caller since this method is also called in MixinOFDynamicLights which