Fixes PriorityQueue class.