Fix for directories being listed