GetWebhookByID returns webhook by given ID. Use this function with caution of accessing unauthorized webhook, which means should only be used in non-user interactive functions.
(id int64)
| 271 | // Use this function with caution of accessing unauthorized webhook, |
| 272 | // which means should only be used in non-user interactive functions. |
| 273 | func GetWebhookByID(id int64) (*Webhook, error) { |
| 274 | return getWebhook(&Webhook{ |
| 275 | ID: id, |
| 276 | }) |
| 277 | } |
| 278 | |
| 279 | // GetWebhookOfRepoByID returns webhook of repository by given ID. |
| 280 | func GetWebhookOfRepoByID(repoID, id int64) (*Webhook, error) { |