When reindexing check for file before trying to open