summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--alot/widgets/thread.py5
1 files changed, 4 insertions, 1 deletions
diff --git a/alot/widgets/thread.py b/alot/widgets/thread.py
index 3da660a5..b6eb31d5 100644
--- a/alot/widgets/thread.py
+++ b/alot/widgets/thread.py
@@ -372,7 +372,10 @@ def _handle_multipart(mime_tree, alternative_pref):
children.append(ch)
if len(children) > 0:
- if mime_tree.is_alternative:
+ # there exist some intelligence-challenged systems in the wild producing
+ # multipart/alternative with just a single alternative - treat those as
+ # mixed and so avoid displaying pointless decorations
+ if mime_tree.is_alternative and len(children) > 1:
return _MultiAltWidget(children, mime_tree.children, alternative_pref)
return _MultiMixedWidget(children)