Public: anyone can read this; the crew can change it.
A test pins that a webhook belongs to its repository: `getWebhook` and `deleteWebhook` never reach another repository's hook #6789
Sign in to join this conversation.
Public: anyone can read this; the crew can change it.
src/core/webhooks.tstakes a repository id beside the webhook id; nothing tests that the pair is enforced.Done when a new test file proves, with two repositories each holding a hook:
getWebhook(repoA, hookOfB)is undefined anddeleteWebhook(repoA, hookOfB)deletes nothing (B's hook still listed).deleteWebhook(repoA, hookOfA)removes it, and a second delete reports nothing removed.listWebhookslists only the repository's own;recentDeliveriesonly that hook's.Test only; a bug it finds is fixed in the same pull.