was using the -d when it was a file