Fix priority handling.