diff --git a/README.md b/README.md index 7f11ec1..653c8fb 100644 --- a/README.md +++ b/README.md @@ -32,8 +32,6 @@ The following options are allowed: - `key`: the name of the key to pub/sub events on as prefix (`socket.io`) - `host`: host to connect to redis on (`localhost`) - `port`: port to connect to redis on (`6379`) -- `socket`: unix domain socket to connect to redis (`"/tmp/redis.sock"`). Will - be used instead of the host and port options if specified. - `pubClient`: optional, the redis client to publish events on - `subClient`: optional, the redis client to subscribe to events on diff --git a/index.js b/index.js index 2ae3f83..56bc0d8 100644 --- a/index.js +++ b/index.js @@ -42,7 +42,6 @@ function adapter(uri, opts){ } // opts - var socket = opts.socket; var host = opts.host || '127.0.0.1'; var port = Number(opts.port || 6379); var pub = opts.pubClient; @@ -50,11 +49,8 @@ function adapter(uri, opts){ var prefix = opts.key || 'socket.io'; // init clients if needed - if (!pub) pub = socket ? redis(socket) : redis(port, host); - if (!sub) sub = socket - ? redis(socket, { detect_buffers: true }) - : redis(port, host, {detect_buffers: true}); - + if (!pub) pub = redis(port, host); + if (!sub) sub = redis(port, host, { detect_buffers: true }); // this server's key var uid = uid2(6);