This commit is contained in:
Jeff McAffer 2017-04-11 12:45:48 -07:00
Родитель 8858197a0b
Коммит ca135a9252
2 изменённых файлов: 2 добавлений и 2 удалений

Просмотреть файл

@ -818,7 +818,7 @@ class GitHubProcessor {
orgId = document.organization ? document.organization.id : null;
}
qualifier = qualifier || (repo ? `urn:repo:${repo}` : `urn:org:${orgId}`);
const id = document.id || request.payload.guid;
const id = document.id || request.payload.deliveryId;
request.linkResource('self', `${qualifier}:${request.type}:${id}`);
request.linkSiblings(`${qualifier}:${request.type}s`);

Просмотреть файл

@ -32,7 +32,7 @@ router.post('/', wrap(function* (request, response, next) {
const event = JSON.parse(request.body);
const eventsUrl = event.repository ? event.repository.events_url : event.organization.events_url;
const result = new Request('event_trigger', `${eventsUrl}/${deliveryId}`);
result.payload = { body: event, etag: 1, fetchedAt: moment.utc().toISOString(), type: eventType, guid: deliveryId };
result.payload = { body: event, etag: 1, fetchedAt: moment.utc().toISOString(), type: eventType, deliveryId: deliveryId };
// requests off directly off the event feed do not need exclusivity
result.requiresLock = false;
// if the event is for a private repo, mark the request as needing private access.