Skip to content

Commit a88776b

Browse files
authored
chore: remove dead code from PRChecker (#919)
1 parent ef135f5 commit a88776b

File tree

1 file changed

+1
-13
lines changed

1 file changed

+1
-13
lines changed

lib/pr_checker.js

+1-13
Original file line numberDiff line numberDiff line change
@@ -30,15 +30,6 @@ const FAST_TRACK_RE = /^Fast-track has been requested by @(.+?)\. Please 👍 to
3030
const FAST_TRACK_MIN_APPROVALS = 2;
3131
const GIT_CONFIG_GUIDE_URL = 'https://github.com/nodejs/node/blob/99b1ada/doc/guides/contributing/pull-requests.md#step-1-fork';
3232

33-
// eslint-disable-next-line no-extend-native
34-
Array.prototype.findLastIndex ??= function findLastIndex(fn) {
35-
const reversedIndex = Reflect.apply(
36-
Array.prototype.findIndex,
37-
this.slice().reverse(),
38-
arguments);
39-
return reversedIndex === -1 ? -1 : this.length - reversedIndex - 1;
40-
};
41-
4233
export default class PRChecker {
4334
/**
4435
* @param {{}} cli
@@ -49,7 +40,7 @@ export default class PRChecker {
4940
this.request = request;
5041
this.data = data;
5142
const {
52-
pr, reviewers, comments, reviews, commits, collaborators
43+
pr, reviewers, comments, reviews, commits
5344
} = data;
5445
this.reviewers = reviewers;
5546
this.pr = pr;
@@ -61,9 +52,6 @@ export default class PRChecker {
6152
this.reviews = reviews;
6253
this.commits = commits;
6354
this.argv = argv;
64-
this.collaboratorEmails = new Set(
65-
Array.from(collaborators).map((c) => c[1].email)
66-
);
6755
}
6856

6957
get waitTimeSingleApproval() {

0 commit comments

Comments
 (0)