sup

A curses threads-with-tags style email client

sup.git

git clone https://supmua.dev/git/sup/
commit bbd20062fed6932cfc9a756da278fca7cc2646ae
parent a51421793eb37bf5222085f7e07d442956c3e7cc
Author: wmorgan <wmorgan@5c8cc53c-5e98-4d25-b20a-d8db53a31250>
Date:   Thu, 29 Nov 2007 18:12:36 +0000

fix from email bug

git-svn-id: svn://rubyforge.org/var/svn/sup/trunk@736 5c8cc53c-5e98-4d25-b20a-d8db53a31250

Diffstat:
M lib/sup/modes/reply-mode.rb | 4 ++--
M lib/sup/person.rb | 3 ++-
2 files changed, 4 insertions(+), 3 deletions(-)
diff --git a/lib/sup/modes/reply-mode.rb b/lib/sup/modes/reply-mode.rb
@@ -27,10 +27,10 @@ class ReplyMode < EditMessageMode
       if @m.recipient_email && (a = AccountManager.account_for(@m.recipient_email))
         [@m.recipient_email, a]
       elsif(b = (@m.to + @m.cc).find { |p| AccountManager.is_account? p })
-        [b.full_address, b]
+        [nil, b]
       else
         c = AccountManager.default_account
-        [c.full_address, c]
+        [nil, c]
       end
 
     ## ignore reply-to for list messages because it's typically set to
diff --git a/lib/sup/person.rb b/lib/sup/person.rb
@@ -114,7 +114,8 @@ class Person
 
   def mediumname; @name || @email; end
 
-  def full_address email=@email
+  def full_address email=nil
+    email ||= @email
     if @name && email
       if @name =~ /[",@]/
         "#{@name.inspect} <#{email}>" # escape quotes