Call trim() on input string

This commit is contained in:
Mattias Erming 2014-09-27 08:56:23 -07:00
parent 35f6f1a677
commit ea5f7b2517
2 changed files with 2 additions and 2 deletions

View File

@ -1,7 +1,7 @@
{ {
"name": "shout", "name": "shout",
"description": "The self-hosted web IRC client", "description": "The self-hosted web IRC client",
"version": "0.37.3", "version": "0.37.4",
"author": "Mattias Erming", "author": "Mattias Erming",
"preferGlobal": true, "preferGlobal": true,
"bin": { "bin": {

View File

@ -200,7 +200,7 @@ Client.prototype.connect = function(args) {
Client.prototype.input = function(data) { Client.prototype.input = function(data) {
var client = this; var client = this;
var text = data.text; var text = data.text.trim();
var target = client.find(data.target); var target = client.find(data.target);
if (text.charAt(0) !== "/") { if (text.charAt(0) !== "/") {
text = "/say " + text; text = "/say " + text;