Commits

Christian Ebert  committed bc5b556

viewhtmlmsg: declare html charset

  • Participants
  • Parent commits eee1593

Comments (0)

Files changed (1)

File muttils/viewhtmlmsg.py

         htmldir = tempfile.mkdtemp('', 'viewhtmlmsg.')
         try:
             htmlfile = os.path.join(htmldir, 'index.html')
+            charset = html.get_param('charset')
             html = html.get_payload(decode=True)
+            if charset:
+                html = html.replace('<head>', '<head><meta charset="%s">' % charset)
             fc = 0
             for part in msg.walk():
                 fc += 1