{"action":"created","issue":{"url":"https://api.github.com/repos/petkaantonov/bluebird/issues/517","labels_url":"https://api.github.com/repos/petkaantonov/bluebird/issues/517/labels{/name}","comments_url":"https://api.github.com/repos/petkaantonov/bluebird/issues/517/comments","events_url":"https://api.github.com/repos/petkaantonov/bluebird/issues/517/events","html_url":"https://github.com/petkaantonov/bluebird/issues/517","id":59485048,"number":517,"title":"second argument for .tap or similar method for rejections","user":{"login":"Janpot","id":2109932,"avatar_url":"https://avatars.githubusercontent.com/u/2109932?v=3","gravatar_id":"","url":"https://api.github.com/users/Janpot","html_url":"https://github.com/Janpot","followers_url":"https://api.github.com/users/Janpot/followers","following_url":"https://api.github.com/users/Janpot/following{/other_user}","gists_url":"https://api.github.com/users/Janpot/gists{/gist_id}","starred_url":"https://api.github.com/users/Janpot/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Janpot/subscriptions","organizations_url":"https://api.github.com/users/Janpot/orgs","repos_url":"https://api.github.com/users/Janpot/repos","events_url":"https://api.github.com/users/Janpot/events{/privacy}","received_events_url":"https://api.github.com/users/Janpot/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":6,"created_at":"2015-03-02T14:07:15Z","updated_at":"2015-03-03T01:30:08Z","closed_at":null,"body":"I often use `.tap(console.log)` for quick debugging. It would be useful for me to have it either work like `.then` so I could do `.tap(null, console.log)` as well to log rejections.\r\nOr to have a similar method that works like `.tap` but is analog to `.catch` as in `.tapRejection(console.log)`."},"comment":{"url":"https://api.github.com/repos/petkaantonov/bluebird/issues/comments/76869203","html_url":"https://github.com/petkaantonov/bluebird/issues/517#issuecomment-76869203","issue_url":"https://api.github.com/repos/petkaantonov/bluebird/issues/517","id":76869203,"user":{"login":"benjamingr","id":1315533,"avatar_url":"https://avatars.githubusercontent.com/u/1315533?v=3","gravatar_id":"","url":"https://api.github.com/users/benjamingr","html_url":"https://github.com/benjamingr","followers_url":"https://api.github.com/users/benjamingr/followers","following_url":"https://api.github.com/users/benjamingr/following{/other_user}","gists_url":"https://api.github.com/users/benjamingr/gists{/gist_id}","starred_url":"https://api.github.com/users/benjamingr/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/benjamingr/subscriptions","organizations_url":"https://api.github.com/users/benjamingr/orgs","repos_url":"https://api.github.com/users/benjamingr/repos","events_url":"https://api.github.com/users/benjamingr/events{/privacy}","received_events_url":"https://api.github.com/users/benjamingr/received_events","type":"User","site_admin":false},"created_at":"2015-03-03T01:30:08Z","updated_at":"2015-03-03T01:30:08Z","body":"@petkaantonov those were my initial thoughts but I can see a flow like:\r\n\r\n    makeRequest().\r\n        tap(null, console.log).\r\n        then(parseRequest).\r\n        then(applyToDb).\r\n        catch(NetworkError, err => retry(attempts-1));\r\n\r\nWhere you might care that the request failed but you handle and recover from it later so from the whole app point of view it's not a rejection."}}