mirror of
https://github.com/tiennm99/is-a-dev.git
synced 2026-10-06 08:14:01 +00:00
Update check-pr-template.js
This commit is contained in:
1 parent
759626cf0e
commit
4bbc190839
1 file changed
+11
@@ -1,4 +1,15 @@
|
||||
const trustedUsers = require("./trusted.json");
|
||||
|
||||
const body = process.env.PR_BODY || "";
|
||||
const authorUsername = process.env.PR_AUTHOR || "";
|
||||
const authorId = Number(process.env.PR_AUTHOR_ID);
|
||||
|
||||
const isTrustedUser = trustedUsers.some((u) => u.id === authorId);
|
||||
|
||||
if (isTrustedUser) {
|
||||
console.log(`PR author "${authorUsername}" is a trusted user. Skipping template validation.`);
|
||||
process.exit(0);
|
||||
}
|
||||
|
||||
const REQUIRED_CHECKBOXES = [
|
||||
"TOS",
|
||||
|
||||
Reference in new issue
Block a user