Add check for external files