The "string" case also assigns the message to responseBody, but inside the  
_trackMessageSize call.
If you look at the discussion about this change, you will see my concerns  
about message size tracking when using binary frames. It's current  
implementation corrupts the data. That is why I skip it all together.


On Fri, 25 Jan 2013 18:19:01 +0200, Markus Staab  
<notifications@github.com> wrote:

>>
>>                      _response.state = 'messageReceived';
>>                      _response.status = 200;
>>
>>                      var message = message.data;
>> -                    var skipCallbackInvocation =  
>> _trackMessageSize(message, _request, _response);
>> -
>> -                    if (!skipCallbackInvocation) {
>> -                        _invokeCallback();
>> -                        _response.responseBody = '';
>> +                    var isString =  typeof(message) == 'string';
>> +                    if(isString){
>> +                        var skipCallbackInvocation =  
>> _trackMessageSize(message, _request, _response);
>> +                       if (!skipCallbackInvocation) {
>> +                           _invokeCallback();
>> +                           _response.responseBody = '';
>> +                       }
>> +                    }else{
>> +                       _response.responseBody = message;
>
> why do you set the messge into the response body? the string case  
> doesn't do that..
>
> ---
> Reply to this email directly or view it on GitHub:
> https://github.com/Atmosphere/atmosphere/pull/856/files#r2776221


-- 
Using Opera's revolutionary email client: http://www.opera.com/mail/