Skip to content

Commit 1c569cf

Browse files
committed
forgot to clean this up when I was debugging
1 parent e41d8e8 commit 1c569cf

File tree

1 file changed

+1
-6
lines changed

1 file changed

+1
-6
lines changed

src/main/java/com/gregtechceu/gtceu/api/machine/multiblock/MultiblockControllerMachine.java

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -209,12 +209,7 @@ public void onStructureInvalid() {
209209
*/
210210
@Override
211211
public void onPartUnload() {
212-
for (var it = parts.iterator(); it.hasNext();) {
213-
var part = it.next();
214-
if (part.self().isInValid()) {
215-
it.remove();
216-
}
217-
}
212+
parts.removeIf(part -> part.self().isInValid());
218213
getMultiblockState().setError(MultiblockState.UNLOAD_ERROR);
219214
if (getLevel() instanceof ServerLevel serverLevel) {
220215
// If structure is formed, invalidate it immediately to update all parts' render states

0 commit comments

Comments
 (0)