Added checking to avoid multiple downloads of same file