fixed bug where only one sample directory could be present