Skip to content

Commit

Permalink
tools: keep Emeriti lists case-insensitive alphabetic
Browse files Browse the repository at this point in the history
The current code does not treat capital and lowercase letters as
equivalent.

PR-URL: #45159
Reviewed-By: Michaël Zasso <targos@protonmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Richard Lau <rlau@redhat.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
  • Loading branch information
Trott authored and danielleadams committed Jan 3, 2023
1 parent 5aa4ea9 commit 62c233c
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion tools/find-inactive-collaborators.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -163,7 +163,7 @@ async function moveCollaboratorToEmeritus(peopleToMove) {
const currentLine = `${collaboratorFirstLine}\n${line}\n`;
// If textToMove is empty, this still works because when undefined is
// used in a comparison with <, the result is always false.
while (textToMove[0] < currentLine) {
while (textToMove[0]?.toLowerCase() < currentLine.toLowerCase()) {
fileContents += textToMove.shift();
}
fileContents += currentLine;
Expand Down
2 changes: 1 addition & 1 deletion tools/find-inactive-tsc.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -198,7 +198,7 @@ async function moveTscToEmeritus(peopleToMove) {
const currentLine = `${memberFirstLine}\n${line}\n`;
// If textToMove is empty, this still works because when undefined is
// used in a comparison with <, the result is always false.
while (textToMove[0] < currentLine) {
while (textToMove[0]?.toLowerCase() < currentLine.toLowerCase()) {
fileContents += textToMove.shift();
}
fileContents += currentLine;
Expand Down

0 comments on commit 62c233c

Please sign in to comment.