Replaces while iterators with foreach call

This commit is contained in:
thatsIch
2014-09-29 09:26:35 +02:00
parent 72106c877d
commit b6ec21c70a
10 changed files with 33 additions and 36 deletions
+4 -3
View File
@@ -135,9 +135,10 @@ public final class ItemList<StackType extends IAEStack> implements IItemList<Sta
@Override
synchronized public StackType getFirstItem()
{
Iterator<StackType> i = this.iterator();
while (i.hasNext())
return i.next();
for (StackType stackType : this)
{
return stackType;
}
return null;
}