Priority increase and duplicate removal fixed