mirror of
https://github.com/status-im/github-webhook-filter.git
synced 2025-01-20 18:49:32 +00:00
feat: filter empty reviews
This commit is contained in:
parent
b9ce7c7fd4
commit
5fb5a26209
@ -20,6 +20,11 @@ export default function filter(headers: Headers, json: any, config: UrlConfig):
|
||||
return "no-op issue event";
|
||||
}
|
||||
|
||||
if (event === "pull_request_review") {
|
||||
if (json.action !== "submitted") return "no-op PR review event";
|
||||
else if (json.review?.body === null) return "empty PR review";
|
||||
}
|
||||
|
||||
const login: string | undefined = json.sender?.login?.toLowerCase();
|
||||
if (
|
||||
login &&
|
||||
|
Loading…
x
Reference in New Issue
Block a user