Fix the function for add an XML Object in a static XML.