remove unnecessary getUnits() call and ArrayList creation, because getUnits() already creates a new list every time.