Avoid creating tempList when not needed.
This commit is contained in:
parent
af8b9e14b8
commit
9a3d55e768
@ -105,9 +105,9 @@ public class PrivateStoreHistoryManager
|
||||
|
||||
public List<ItemHistoryTransaction> getHistory(boolean full)
|
||||
{
|
||||
final List<ItemHistoryTransaction> tempList = new ArrayList<>(_items);
|
||||
if (!full)
|
||||
{
|
||||
final List<ItemHistoryTransaction> tempList = new ArrayList<>(_items);
|
||||
final Map<Integer, Integer> uniqueItemIds = new HashMap<>();
|
||||
for (ItemHistoryTransaction transaction : tempList)
|
||||
{
|
||||
|
@ -105,9 +105,9 @@ public class PrivateStoreHistoryManager
|
||||
|
||||
public List<ItemHistoryTransaction> getHistory(boolean full)
|
||||
{
|
||||
final List<ItemHistoryTransaction> tempList = new ArrayList<>(_items);
|
||||
if (!full)
|
||||
{
|
||||
final List<ItemHistoryTransaction> tempList = new ArrayList<>(_items);
|
||||
final Map<Integer, Integer> uniqueItemIds = new HashMap<>();
|
||||
for (ItemHistoryTransaction transaction : tempList)
|
||||
{
|
||||
|
@ -105,9 +105,9 @@ public class PrivateStoreHistoryManager
|
||||
|
||||
public List<ItemHistoryTransaction> getHistory(boolean full)
|
||||
{
|
||||
final List<ItemHistoryTransaction> tempList = new ArrayList<>(_items);
|
||||
if (!full)
|
||||
{
|
||||
final List<ItemHistoryTransaction> tempList = new ArrayList<>(_items);
|
||||
final Map<Integer, Integer> uniqueItemIds = new HashMap<>();
|
||||
for (ItemHistoryTransaction transaction : tempList)
|
||||
{
|
||||
|
Loading…
Reference in New Issue
Block a user