Modified to not delete existing file