MAINT: tidy up by removing dead code