Merge branch 'jk/prune-with-corrupt-refs'