<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def strip_xml_declaration(file_or_xml):
 """ Removes XML declaration line from file or string passed in. If file_or_xml is not a file or string, it is returned as is. """


    xml_content = _xml_content_to_string(file_or_xml)
    if not isinstance(xml_content, string_types):
        return xml_content

    # For Python 2 compliance: replacement string must not specify unicode u''
    return _XML_DECLARATION_REGEX.sub(r'', xml_content, 1)