only add trailing slashes if doing autoIndex or showDir