chiark / gitweb /
topicedit: add new topic info at front
authorIan Jackson <ijackson@chiark.greenend.org.uk>
Fri, 11 Apr 2014 16:11:08 +0000 (17:11 +0100)
committerIan Jackson <ijackson@chiark.greenend.org.uk>
Fri, 11 Apr 2014 16:11:08 +0000 (17:11 +0100)
topicedit.tcl

index 43ec29f9aa78674147d927fad085baca80061202..9fc4765285ce61bc85196746f5288daae062a64e 100755 (executable)
@@ -43,7 +43,8 @@ proc msg_333 {server code us channel setter when} {
 }
 proc msg_366 {args} {
     global oldtopic topicinfo channel done
-    set newtopic "$oldtopic | $topicinfo"
+    if {![info exists oldtopic]} return
+    set newtopic "$topicinfo | $oldtopic"
     sendout TOPIC $channel $newtopic
     sendout TOPIC $channel
     set done 1