Added listDir function to return all directories of an directory