Skip to content

Commit 3b407aa

Browse files
authored
Fix legacy DFU porting typo. (#2744)
Only affected fabric/(neo)forge but didn't get hit for 6 years apparently.
1 parent 9ea136a commit 3b407aa

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

worldedit-fabric/src/main/java/com/sk89q/worldedit/fabric/FabricDataFixer.java

+1-1
Original file line numberDiff line numberDiff line change
@@ -595,7 +595,7 @@ private static void convertItems(net.minecraft.nbt.CompoundTag nbttagcompound, S
595595
ListTag nbttaglist = nbttagcompound.getList(key, 10);
596596

597597
for (int j = 0; j < nbttaglist.size(); ++j) {
598-
nbttaglist.add(j, convert(LegacyType.ITEM_INSTANCE, nbttaglist.getCompound(j), sourceVer, targetVer));
598+
nbttaglist.set(j, convert(LegacyType.ITEM_INSTANCE, nbttaglist.getCompound(j), sourceVer, targetVer));
599599
}
600600
}
601601

worldedit-neoforge/src/main/java/com/sk89q/worldedit/neoforge/NeoForgeDataFixer.java

+1-1
Original file line numberDiff line numberDiff line change
@@ -595,7 +595,7 @@ private static void convertItems(net.minecraft.nbt.CompoundTag nbttagcompound, S
595595
ListTag nbttaglist = nbttagcompound.getList(key, 10);
596596

597597
for (int j = 0; j < nbttaglist.size(); ++j) {
598-
nbttaglist.add(j, convert(LegacyType.ITEM_INSTANCE, nbttaglist.getCompound(j), sourceVer, targetVer));
598+
nbttaglist.set(j, convert(LegacyType.ITEM_INSTANCE, nbttaglist.getCompound(j), sourceVer, targetVer));
599599
}
600600
}
601601

0 commit comments

Comments
 (0)