Only append : to a tabbed nick if it's the first word #232
authorDarren <darren@darrenwhitlen.com>
Thu, 6 Jun 2013 12:15:21 +0000 (13:15 +0100)
committerDarren <darren@darrenwhitlen.com>
Thu, 6 Jun 2013 12:15:21 +0000 (13:15 +0100)
client/assets/src/views/controlbox.js

index 58c18b41a1baa7a03f717e3a60481150d042d313..0d8d13d580b33ee9ea71b42d7f52dd4bf0b4c8bb 100644 (file)
@@ -167,6 +167,10 @@ _kiwi.view.ControlBox = Backbone.View.extend({
                 if (tokens[tokens.length-1] == ':')
                     tokens.pop();
 
+                // Only add the trailing text if not at the beginning of the line
+                if (tokens.length > 1)
+                    trailing = '';
+
                 nick  = tokens[tokens.length - 1];
 
                 if (this.tabcomplete.prefix === '') {