generated from nhcarrigan/template
This commit is contained in:
@@ -8,6 +8,7 @@ export const ids = {
|
|||||||
channels: {
|
channels: {
|
||||||
mentorshipGoalForum: "1400629118110011526",
|
mentorshipGoalForum: "1400629118110011526",
|
||||||
mentorshipProjectForum: "1400616702265266186",
|
mentorshipProjectForum: "1400616702265266186",
|
||||||
|
naomiDiscussionForum: "1408154690121633917",
|
||||||
news: "1407804798677418198",
|
news: "1407804798677418198",
|
||||||
resumeReviewForum: "1407807555266154496",
|
resumeReviewForum: "1407807555266154496",
|
||||||
},
|
},
|
||||||
@@ -19,6 +20,10 @@ export const ids = {
|
|||||||
representing: "1407861842847469598",
|
representing: "1407861842847469598",
|
||||||
},
|
},
|
||||||
tags: {
|
tags: {
|
||||||
|
discussion: {
|
||||||
|
member: "1408167311516500071",
|
||||||
|
naomi: "1408167262803853493",
|
||||||
|
},
|
||||||
goal: {
|
goal: {
|
||||||
member: "1406355263811752147",
|
member: "1406355263811752147",
|
||||||
naomi: "1406355221847871740",
|
naomi: "1406355221847871740",
|
||||||
|
|||||||
@@ -38,7 +38,6 @@ amari.discord.once(Events.ClientReady, () => {
|
|||||||
`Authenticated to Discord as ${amari.discord.user?.username ?? "unknown"}`);
|
`Authenticated to Discord as ${amari.discord.user?.username ?? "unknown"}`);
|
||||||
void cacheData(amari);
|
void cacheData(amari);
|
||||||
scheduleJob("post news", "0 * * * *", async() => {
|
scheduleJob("post news", "0 * * * *", async() => {
|
||||||
await logger.log("debug", "Fetching tech news.");
|
|
||||||
await postFreeCodeCampNews(amari);
|
await postFreeCodeCampNews(amari);
|
||||||
await postHackerNews(amari);
|
await postHackerNews(amari);
|
||||||
});
|
});
|
||||||
|
|||||||
@@ -25,6 +25,11 @@ const getTag = (id: string, type: "naomi" | "member"): string => {
|
|||||||
? ids.tags.resume.naomi
|
? ids.tags.resume.naomi
|
||||||
: ids.tags.resume.member;
|
: ids.tags.resume.member;
|
||||||
}
|
}
|
||||||
|
if (id === ids.channels.naomiDiscussionForum) {
|
||||||
|
return type === "naomi"
|
||||||
|
? ids.tags.discussion.naomi
|
||||||
|
: ids.tags.discussion.member;
|
||||||
|
}
|
||||||
return "";
|
return "";
|
||||||
};
|
};
|
||||||
|
|
||||||
@@ -48,11 +53,13 @@ export const updateMentorshipThread = async(
|
|||||||
mentorshipGoalForum,
|
mentorshipGoalForum,
|
||||||
mentorshipProjectForum,
|
mentorshipProjectForum,
|
||||||
resumeReviewForum,
|
resumeReviewForum,
|
||||||
|
naomiDiscussionForum,
|
||||||
} = ids.channels;
|
} = ids.channels;
|
||||||
if (![
|
if (![
|
||||||
mentorshipGoalForum,
|
mentorshipGoalForum,
|
||||||
mentorshipProjectForum,
|
mentorshipProjectForum,
|
||||||
resumeReviewForum,
|
resumeReviewForum,
|
||||||
|
naomiDiscussionForum,
|
||||||
].includes(channel.parent.id)) {
|
].includes(channel.parent.id)) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user