Permalink
Browse files

Allowed for headers with a : in them

  • Loading branch information...
magicmonkey committed Nov 14, 2010
1 parent d38e8ee commit f0963296545040de5ce200b6930871e546ea98e5
Showing with 2 additions and 1 deletion.
  1. +2 −1 stomp.js
View
@@ -88,7 +88,8 @@ Connection.prototype.parseHeader = function(s){
var headers = {};
for(var i=0; i<lines.length; i++){
var header = lines[i].split(":");
- headers[header[0].trim()] = header[1].trim();
+ var headerName = header.shift().trim();
+ headers[headerName] = header.join(':').trim();
}
return headers;
};

0 comments on commit f096329

Please sign in to comment.