Commit ce5b86ed authored by Ben Boeckel's avatar Ben Boeckel
Browse files

webhooks: expose the confidential issue event flag

Fixes #11
parent becce676
...@@ -195,6 +195,7 @@ impl Gitlab { ...@@ -195,6 +195,7 @@ impl Gitlab {
fn event_flags(events: WebhookEvents) -> Vec<(&'static str, &'static str)> { fn event_flags(events: WebhookEvents) -> Vec<(&'static str, &'static str)> {
vec![("job_events", Self::bool_param_value(events.job())), vec![("job_events", Self::bool_param_value(events.job())),
("issues_events", Self::bool_param_value(events.issues())), ("issues_events", Self::bool_param_value(events.issues())),
("confidential_issues_events", Self::bool_param_value(events.confidential_issues())),
("merge_requests_events", Self::bool_param_value(events.merge_requests())), ("merge_requests_events", Self::bool_param_value(events.merge_requests())),
("note_events", Self::bool_param_value(events.note())), ("note_events", Self::bool_param_value(events.note())),
("pipeline_events", Self::bool_param_value(events.pipeline())), ("pipeline_events", Self::bool_param_value(events.pipeline())),
......
...@@ -349,6 +349,8 @@ pub struct WebhookEvents { ...@@ -349,6 +349,8 @@ pub struct WebhookEvents {
job: bool, job: bool,
/// Whether to receive issue events of not. /// Whether to receive issue events of not.
issues: bool, issues: bool,
/// Whether to receive confidential issue events of not.
confidential_issues: bool,
/// Whether to receive merge request events of not. /// Whether to receive merge request events of not.
merge_requests: bool, merge_requests: bool,
/// Whether to receive note (comment) events of not. /// Whether to receive note (comment) events of not.
...@@ -367,6 +369,7 @@ impl WebhookEvents { ...@@ -367,6 +369,7 @@ impl WebhookEvents {
WebhookEvents { WebhookEvents {
job: false, job: false,
issues: false, issues: false,
confidential_issues: false,
merge_requests: false, merge_requests: false,
note: false, note: false,
pipeline: false, pipeline: false,
...@@ -377,6 +380,7 @@ impl WebhookEvents { ...@@ -377,6 +380,7 @@ impl WebhookEvents {
with_event!{with_job, job} with_event!{with_job, job}
with_event!{with_issues, issues} with_event!{with_issues, issues}
with_event!{with_confidential_issues, issues}
with_event!{with_merge_requests, merge_requests} with_event!{with_merge_requests, merge_requests}
with_event!{with_note, note} with_event!{with_note, note}
with_event!{with_pipeline, pipeline} with_event!{with_pipeline, pipeline}
...@@ -385,6 +389,7 @@ impl WebhookEvents { ...@@ -385,6 +389,7 @@ impl WebhookEvents {
get_event!{job} get_event!{job}
get_event!{issues} get_event!{issues}
get_event!{confidential_issues}
get_event!{merge_requests} get_event!{merge_requests}
get_event!{note} get_event!{note}
get_event!{pipeline} get_event!{pipeline}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment