Fixes implementation as per spec 06 tells

New priority queue is developed because of old implementing priority approach is wrong considering new spec.