wooga/eredis — pull request #59 by mediocreshark (2014-09-24 20:25:23+00:00)
Title: don't duplicate channel in state#channels if subscribe is called multiple times on it

If you call `eredis_sub:subscribe(Conn, Channels)` multiple times with the same channel list, the channel list held in state was just having duplicates added onto it.

The obvious solution is "well, don't do that", but it's useful to do as a form of pinging the server, since very few commands are actually allowed to be called in subscribe mode. If you're worried about a long-held, largely idle connection you can't just call `PING` now and then, instead I re-subscribe to one of the channels I know I'm subscribed to. This was causing that strategy problems, unfortunately.