fixed error

forgot to set $file to dir + name so had 404 error