implemented behavior to avoid overriding files unnecessarily