priorOnly argument and bug fixes