Skip to content

Commit

Permalink
Apply Prettier Formatting Fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
bhavberi authored and github-actions[bot] committed May 27, 2024
1 parent af9f59b commit 1741e05
Showing 1 changed file with 15 additions and 7 deletions.
22 changes: 15 additions & 7 deletions src/app/about/clubs-council/page.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,11 @@ export default async function ClubsCouncil() {
const executiveMembers = members
?.map((member) => {
const { roles } = member;
const executiveBoardRoles = filterRoles(roles, executiveBoardWords, techTeamWords);
const executiveBoardRoles = filterRoles(
roles,
executiveBoardWords,
techTeamWords,
);
const newMember = { ...member, roles: executiveBoardRoles };
return newMember;
})
Expand All @@ -49,14 +53,18 @@ export default async function ClubsCouncil() {
?.map((member) => {
const { roles } = member;
const advisorWordsCombined = advisorWords.concat(executiveBoardWords);
const advisorRoles = filterRoles(roles, advisorWordsCombined, techTeamWords);
const advisorRoles = filterRoles(
roles,
advisorWordsCombined,
techTeamWords,
);
const newMember = { ...member, roles: advisorRoles };
return newMember;
})
?.filter((member) => {
const role0 = member.roles[0]?.name.toLowerCase();
const matchesAdvisoryFilterWords = advisorWords.some((word) =>
role0.includes(word)
role0.includes(word),
);

return matchesAdvisoryFilterWords && member.roles.length > 0;
Expand Down Expand Up @@ -136,10 +144,10 @@ const filterRoles = (roles, filterWords, unfilterWords = []) => {
const { name, endYear } = role;
const lowercaseName = name.toLowerCase();
const matchesFilterWords = filterWords.some((word) =>
lowercaseName.includes(word)
lowercaseName.includes(word),
);
const matchesUnfilterWords = unfilterWords.some((word) =>
lowercaseName.includes(word)
lowercaseName.includes(word),
);
return matchesFilterWords && !matchesUnfilterWords && endYear === null;
});
Expand All @@ -150,10 +158,10 @@ const filterRoles = (roles, filterWords, unfilterWords = []) => {
const { name, endYear } = role;
const lowercaseName = name.toLowerCase();
const matchesFilterWords = filterWords.some((word) =>
lowercaseName.includes(word)
lowercaseName.includes(word),
);
const matchesUnfilterWords = unfilterWords.some((word) =>
lowercaseName.includes(word)
lowercaseName.includes(word),
);
return matchesFilterWords && !matchesUnfilterWords;
});
Expand Down

0 comments on commit 1741e05

Please sign in to comment.