diff --git a/ql/lib/codeql/actions/security/SelfHostedQuery.qll b/ql/lib/codeql/actions/security/SelfHostedQuery.qll index 94c6c49a34b..898af1a699a 100644 --- a/ql/lib/codeql/actions/security/SelfHostedQuery.qll +++ b/ql/lib/codeql/actions/security/SelfHostedQuery.qll @@ -14,7 +14,7 @@ string selfHostedRunnerRegexp() { */ predicate staticallyIdentifiedSelfHostedRunner(Job job) { exists(string label | - job.getATriggerEvent() = + job.getATriggerEvent().getName() = ["pull_request", "pull_request_review", "pull_request_review_comment", "pull_request_target"] and label = job.getARunsOnLabel() and not label.regexpMatch(selfHostedRunnerRegexp())