{"issue":{"created_at":"2011-11-24T16:17:50Z","state":"closed","updated_at":"2011-11-30T18:40:36Z","comments":3,"user":{"gravatar_id":"f046ac6b545879813eb967a0455aa630","id":82050,"url":"https://api.github.com/users/rmehner","avatar_url":"https://secure.gravatar.com/avatar/f046ac6b545879813eb967a0455aa630?d=https://a248.e.akamai.net/assets.github.com%2Fimages%2Fgravatars%2Fgravatar-140.png","login":"rmehner"},"body":"Hi there,\r\n\r\nas you might know Badgeville pages it's result with an default page size of 10 entries.\r\n\r\nThat means that if you have more than 10 reward definitions the badgeville client will only return the first 10. That wouldn't be such a problem as it would be easy to patch the make_call that happens there to use `:per_page`.\r\n\r\nUnfortunately the maximum number of items that are currently allowed with the `:per_page` parameter is 50. So if you have more than 50 you'll have the problem again.\r\n\r\nThat's why the implementation of the method is now as it is. I'm not too happy with the implementation but had no better idea at the moment. It works at least.\r\n\r\nThat also fixed a subtle bug that wouldn't allow to award a reward to a user via `award` if the reward is not under the first 10 rewards returned.\r\n\r\nWe have the same problem in `get_activities` and `get_rewards`, so maybe we should work on a more generic solution to the problem but I first wanted to have your feedback and thoughts on it, then in the end it's your project after all :)\r\n\r\nGreetings,\r\n- Robin","assignee":null,"id":2343064,"number":5,"labels":[],"pull_request":{"patch_url":"https://github.com/KeasInc/badgeville/pull/5.patch","html_url":"https://github.com/KeasInc/badgeville/pull/5","diff_url":"https://github.com/KeasInc/badgeville/pull/5.diff"},"title":"Page through all reward_definitions","closed_at":"2011-11-30T17:59:53Z","html_url":"https://github.com/KeasInc/badgeville/issues/5","url":"https://api.github.com/repos/KeasInc/badgeville/issues/5","milestone":null},"action":"created","comment":{"created_at":"2011-11-30T18:40:36Z","updated_at":"2011-11-30T18:40:36Z","user":{"gravatar_id":"c7cb70e24ae959ddd5b64fb3e494ad31","id":255209,"url":"https://api.github.com/users/giladbu","avatar_url":"https://secure.gravatar.com/avatar/c7cb70e24ae959ddd5b64fb3e494ad31?d=https://a248.e.akamai.net/assets.github.com%2Fimages%2Fgravatars%2Fgravatar-140.png","login":"giladbu"},"body":"see https://github.com/KeasInc/badgeville/commit/3371d51856363c7b1b3c2ef741c8846c3c78f264\r\n\r\nI generalized it a bit to all GET calls and made it the default for rewards and reward definitions","id":2964099,"url":"https://api.github.com/repos/KeasInc/badgeville/issues/comments/2964099"}}