backstrokeapp / server

:swimmer: A Github bot to keep repository forks up to date with their upstream.
https://backstroke.co
MIT License
667 stars 62 forks source link

Fix paging #72

Closed 1egoman closed 7 years ago

1egoman commented 7 years ago

Paging was broken when we migrated to sequelize, but it turns out that nothing used it so it wasn't noticed. I'm working on fixing that before https://github.com/backstrokeapp/dashboard/issues/4 is attempted.

Example response:

{
  "page": 3,
  "data": [
    {
      "id": 248,
      "name": "My fork of nicss",
      "enabled": true,
      "webhook": "59305a11edee18001c240d58",
      "createdAt": "2017-10-07T19:01:21.914Z",
      "lastSyncedAt": "2017-10-08T19:07:36.304Z",
      "fork": {
        "type": "repo",
        "owner": "1egoman",
        "repo": "nicss",
        "isFork": true,
        "branches": [
          "contributing-doc",
          "master",
          "npm-publish-on-push"
        ],
        "branch": "master"
      },
      "upstream": {
        "type": "repo",
        "owner": "densityco",
        "repo": "nicss",
        "branches": [
          "contributing-doc",
          "master",
          "npm-publish-on-push"
        ],
        "branch": "master"
      }
    },
    (other links here...)
  ]
}