sup

A curses threads-with-tags style email client

sup.git

git clone https://supmua.dev/git/sup/
commit bd34ed37c6c845085dcb978ab77e17c23387705a
parent aa1a09eed4c1aa91754e64442febfef8e3ebb9d5
Author: akojo <atte.kojo@gmail.com>
Date:   Tue,  1 Oct 2013 08:48:43 +0200

Make sure m.snippet is not nil before trying to fix_encoding!

Diffstat:
M lib/sup/modes/thread_view_mode.rb | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/lib/sup/modes/thread_view_mode.rb b/lib/sup/modes/thread_view_mode.rb
@@ -786,7 +786,7 @@ private
       @person_lines[start] = m.from
       [[prefix_widget, open_widget, new_widget, attach_widget, starred_widget,
         [color,
-        "#{m.from ? m.from.mediumname.fix_encoding! : '?'}, #{m.date.to_nice_s.fix_encoding!} (#{m.date.to_nice_distance_s.fix_encoding!})  #{m.snippet.fix_encoding!}"]]]
+        "#{m.from ? m.from.mediumname.fix_encoding! : '?'}, #{m.date.to_nice_s.fix_encoding!} (#{m.date.to_nice_distance_s.fix_encoding!})  #{m.snippet ? m.snippet.fix_encoding! : ''}"]]]
 
     when :detailed
       @person_lines[start] = m.from