{"action":"created","issue":{"url":"https://api.github.com/repos/NodeRedis/node_redis/issues/1047","repository_url":"https://api.github.com/repos/NodeRedis/node_redis","labels_url":"https://api.github.com/repos/NodeRedis/node_redis/issues/1047/labels{/name}","comments_url":"https://api.github.com/repos/NodeRedis/node_redis/issues/1047/comments","events_url":"https://api.github.com/repos/NodeRedis/node_redis/issues/1047/events","html_url":"https://github.com/NodeRedis/node_redis/pull/1047","id":151486519,"number":1047,"title":"Adding send_command_buf function sending reply as Buffers instead of Strings","user":{"login":"vitaliylag","id":12641771,"avatar_url":"https://avatars.githubusercontent.com/u/12641771?v=3","gravatar_id":"","url":"https://api.github.com/users/vitaliylag","html_url":"https://github.com/vitaliylag","followers_url":"https://api.github.com/users/vitaliylag/followers","following_url":"https://api.github.com/users/vitaliylag/following{/other_user}","gists_url":"https://api.github.com/users/vitaliylag/gists{/gist_id}","starred_url":"https://api.github.com/users/vitaliylag/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/vitaliylag/subscriptions","organizations_url":"https://api.github.com/users/vitaliylag/orgs","repos_url":"https://api.github.com/users/vitaliylag/repos","events_url":"https://api.github.com/users/vitaliylag/events{/privacy}","received_events_url":"https://api.github.com/users/vitaliylag/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":2,"created_at":"2016-04-27T20:45:29Z","updated_at":"2016-04-29T10:05:25Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/NodeRedis/node_redis/pulls/1047","html_url":"https://github.com/NodeRedis/node_redis/pull/1047","diff_url":"https://github.com/NodeRedis/node_redis/pull/1047.diff","patch_url":"https://github.com/NodeRedis/node_redis/pull/1047.patch"},"body":"Adding send_command_buf function. The same as send_command but reply will be sent to callbacks as Buffers instead of Strings."},"comment":{"url":"https://api.github.com/repos/NodeRedis/node_redis/issues/comments/215675404","html_url":"https://github.com/NodeRedis/node_redis/pull/1047#issuecomment-215675404","issue_url":"https://api.github.com/repos/NodeRedis/node_redis/issues/1047","id":215675404,"user":{"login":"vitaliylag","id":12641771,"avatar_url":"https://avatars.githubusercontent.com/u/12641771?v=3","gravatar_id":"","url":"https://api.github.com/users/vitaliylag","html_url":"https://github.com/vitaliylag","followers_url":"https://api.github.com/users/vitaliylag/followers","following_url":"https://api.github.com/users/vitaliylag/following{/other_user}","gists_url":"https://api.github.com/users/vitaliylag/gists{/gist_id}","starred_url":"https://api.github.com/users/vitaliylag/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/vitaliylag/subscriptions","organizations_url":"https://api.github.com/users/vitaliylag/orgs","repos_url":"https://api.github.com/users/vitaliylag/repos","events_url":"https://api.github.com/users/vitaliylag/events{/privacy}","received_events_url":"https://api.github.com/users/vitaliylag/received_events","type":"User","site_admin":false},"created_at":"2016-04-29T10:05:25Z","updated_at":"2016-04-29T10:05:25Z","body":"> And using a try catch block around send_command destroys the purpose of the parameter validation.\r\n\r\nI don't use try catch, I use try finally.\r\n\r\n> but instead add a new parameter\r\n\r\nCalling command not added to node_redis yet will be uncomfortably because parameters will be too difficult.\r\n\r\n> add a buffer function for each command\r\n\r\nI think great idea. And delete uppercase commands. If somebody use them he can just copy them by himself. Or you just can add Redis.createUpperCaseCommands() function that will copy all commands. Actually you can also add Redis.createBufferCommands() function. If need I can implement them.\r\n\r\n> It won't work though as it's currently suggested. The function would have to make sure that the parser returns buffers from that point on without changing the results of any other call no matter what option is set.\r\n\r\nSorry, I didn't understand (I guess my English is bad). «It won't work» — my function (send_command_buf)? «without changing the results of any other call» — my function doesn't change other calls replies.\r\n"}}