• Jérome Perrin's avatar
    TextDocument: don't change xml documents content type · 62f09430
    Jérome Perrin authored
    if their content type ended in xml ( such as image/svg+xml ),
    TextDocument._convertToBaseFormat was resetting the content type to
    application/xml.
    
    When doing something like:
    
      wp = web_page_module.newContent(
        portal_type='Web Page',
        content_type='image/svg+xml',
        text_content=svg
      )
    
    wp.getContentType() was sometimes 'image/svg+xml' sometimes
    'application/xml', depending on the order of edit.
    62f09430
document.erp5.TextDocument.py 17.1 KB