Clean File Add check function and clean broken keys