change to use split, rather than basename in getting 'final part'