{"action":"closed","issue":{"url":"https://api.github.com/repos/tgriesser/bookshelf/issues/686","labels_url":"https://api.github.com/repos/tgriesser/bookshelf/issues/686/labels{/name}","comments_url":"https://api.github.com/repos/tgriesser/bookshelf/issues/686/comments","events_url":"https://api.github.com/repos/tgriesser/bookshelf/issues/686/events","html_url":"https://github.com/tgriesser/bookshelf/issues/686","id":66607745,"number":686,"title":"Bookshelf + Express: idiomatic way to call next()","user":{"login":"olalonde","id":416585,"avatar_url":"https://avatars.githubusercontent.com/u/416585?v=3","gravatar_id":"","url":"https://api.github.com/users/olalonde","html_url":"https://github.com/olalonde","followers_url":"https://api.github.com/users/olalonde/followers","following_url":"https://api.github.com/users/olalonde/following{/other_user}","gists_url":"https://api.github.com/users/olalonde/gists{/gist_id}","starred_url":"https://api.github.com/users/olalonde/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/olalonde/subscriptions","organizations_url":"https://api.github.com/users/olalonde/orgs","repos_url":"https://api.github.com/users/olalonde/repos","events_url":"https://api.github.com/users/olalonde/events{/privacy}","received_events_url":"https://api.github.com/users/olalonde/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"milestone":null,"comments":3,"created_at":"2015-04-06T13:34:54Z","updated_at":"2015-04-07T10:21:56Z","closed_at":"2015-04-07T10:21:56Z","body":"Right now I'm doing something like this:\r\n\r\n```javascript\r\nfunction someMiddleware(req, res, next) {\r\n   req.user.load(['posts']).then(next.bind(null, null)).catch(next);\r\n}\r\n```\r\n\r\nand was wondering if there was a less verbose way to do this. What I want is to call next(err) when there is an error and otherwise just call next().\r\n\r\nI know this is not Bookshelf specific but since it is pretty common to use Express+Bookshelf, I was wondering what the idiomatic way to do this would be."}}