udpated to test for symbolic links