Excluding recipient with socket_id does not work #104

Closed
steverandy opened this Issue Apr 1, 2013 · 3 comments

Comments

Projects
None yet
3 participants

I'm using latest slanger v0.3.7 and pusher gem v0.11.3.

With the following code, pusher client still receives the "list_updated" event. I have checked that the socket_id is the same.

Pusher.trigger current_user.pusher_channel, "list_updated", {:id => @list.id}, {:socket_id => request.headers["X-Pusher-Socket-ID"]}

From slanger log

[[:sending_frame,
  :text,
  "{\"event\":\"list_updated\",\"data\":\"{\\\"id\\\":\\\"5159b8918b6915004c000001\\\"}\",\"channel\":\"user_1fe6fb5990a8819f7cf6\"}"]]

I remember this works on the earlier version of slanger.

Contributor

gma commented Jul 22, 2014

I did a bit of digging. Looks like it was implemented in ce0751b and broken in 16bd5ee (at least, the unless socket_id == @socket_id clause was removed then, and perhaps was supposed to be put back later – @markburns ?) .

No time to investigate further right now...

Owner

stevegraham commented Jul 22, 2014

@gma thanks for looking into it, you're the man. p.s. when are you next in London?

Contributor

gma commented Jul 22, 2014

@stevegraham No bother – I had to code around it quickly somewhere, so thought I'd see if I could do a PR in ten minutes (I couldn't).

Might be down again in August. It's a fairly regular event at the moment (visiting users).

@stevegraham stevegraham self-assigned this Dec 26, 2014

@markburns markburns closed this in #184 May 12, 2015

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment