{"action":"created","issue":{"url":"https://api.github.com/repos/matthew-andrews/denodeify/issues/23","labels_url":"https://api.github.com/repos/matthew-andrews/denodeify/issues/23/labels{/name}","comments_url":"https://api.github.com/repos/matthew-andrews/denodeify/issues/23/comments","events_url":"https://api.github.com/repos/matthew-andrews/denodeify/issues/23/events","html_url":"https://github.com/matthew-andrews/denodeify/issues/23","id":94856818,"number":23,"title":"Document using denodeify against a method","user":{"login":"BrianRossmajer","id":4728461,"avatar_url":"https://avatars.githubusercontent.com/u/4728461?v=3","gravatar_id":"","url":"https://api.github.com/users/BrianRossmajer","html_url":"https://github.com/BrianRossmajer","followers_url":"https://api.github.com/users/BrianRossmajer/followers","following_url":"https://api.github.com/users/BrianRossmajer/following{/other_user}","gists_url":"https://api.github.com/users/BrianRossmajer/gists{/gist_id}","starred_url":"https://api.github.com/users/BrianRossmajer/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/BrianRossmajer/subscriptions","organizations_url":"https://api.github.com/users/BrianRossmajer/orgs","repos_url":"https://api.github.com/users/BrianRossmajer/repos","events_url":"https://api.github.com/users/BrianRossmajer/events{/privacy}","received_events_url":"https://api.github.com/users/BrianRossmajer/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":3,"created_at":"2015-07-14T03:00:32Z","updated_at":"2015-08-19T19:13:39Z","closed_at":null,"body":"It would be great if the documentation would mention how to denodeify methods as well as functions; perhaps something like this (borrowing from the Q library documentation):\r\n\r\nNote that if you have a method that uses the Node.js callback pattern, as opposed to just a function, you will need to bind its this value before passing it to denodeify, like so:\r\n\r\nvar Kitty = mongoose.model(\"Kitty\");\r\nvar brokenFind = denodeify( Kitty.find );  // the find method won't have the right 'this' defined\r\nvar findKitties = denodeify( Kitty.find.bind(Kitty) );"},"comment":{"url":"https://api.github.com/repos/matthew-andrews/denodeify/issues/comments/132746859","html_url":"https://github.com/matthew-andrews/denodeify/issues/23#issuecomment-132746859","issue_url":"https://api.github.com/repos/matthew-andrews/denodeify/issues/23","id":132746859,"user":{"login":"marvinroger","id":990773,"avatar_url":"https://avatars.githubusercontent.com/u/990773?v=3","gravatar_id":"","url":"https://api.github.com/users/marvinroger","html_url":"https://github.com/marvinroger","followers_url":"https://api.github.com/users/marvinroger/followers","following_url":"https://api.github.com/users/marvinroger/following{/other_user}","gists_url":"https://api.github.com/users/marvinroger/gists{/gist_id}","starred_url":"https://api.github.com/users/marvinroger/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/marvinroger/subscriptions","organizations_url":"https://api.github.com/users/marvinroger/orgs","repos_url":"https://api.github.com/users/marvinroger/repos","events_url":"https://api.github.com/users/marvinroger/events{/privacy}","received_events_url":"https://api.github.com/users/marvinroger/received_events","type":"User","site_admin":false},"created_at":"2015-08-19T19:13:39Z","updated_at":"2015-08-19T19:13:39Z","body":"I just got stuck for an hour about that. @BrianRossmajer, the text you wrote is perfectly clear, I think it is fine. Could you submit a PR if @matthew-andrews is ok?"}}