commit d2b7b9ee8ea9ce2dc93c518d8b9e572af98ad6ed
parent ba2116dedc3a32d7382e128172c7a8151c5ecf2d
Author: wmorgan <wmorgan@5c8cc53c-5e98-4d25-b20a-d8db53a31250>
Date: Mon, 19 Feb 2007 22:43:57 +0000
bugfix for edit labels on nil thread (thanks to ryan king)
git-svn-id: svn://rubyforge.org/var/svn/sup/trunk@332 5c8cc53c-5e98-4d25-b20a-d8db53a31250
Diffstat:
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/lib/sup/modes/thread-index-mode.rb b/lib/sup/modes/thread-index-mode.rb
@@ -275,7 +275,7 @@ class ThreadIndexMode < LineCursorMode
def apply_to_tagged; @tags.apply_to_tagged; end
def edit_labels
- thread = @threads[curpos]
+ thread = @threads[curpos] or return
speciall = (@hidden_labels + LabelManager::RESERVED_LABELS).uniq
keepl, modifyl = thread.labels.partition { |t| speciall.member? t }
label_string = modifyl.join(" ")