Fix Date Bugggggggggggggggggggggggggggggggggggggggg
This commit is contained in:
parent
5345ae4761
commit
693979cbd2
1 changed files with 18 additions and 2 deletions
|
@ -112,7 +112,23 @@ module.exports = {
|
|||
}
|
||||
}
|
||||
|
||||
messageMap = new Map([...messageMap.entries()].sort((a, b) => a - b));
|
||||
messageMap = new Map([...messageMap.entries()].sort((a, b) => {
|
||||
if (a[1] == b[1]) {
|
||||
if (b > a) {
|
||||
return -1;
|
||||
}
|
||||
else if (a < b) {
|
||||
return 1;
|
||||
}
|
||||
return 0;
|
||||
}
|
||||
else if (a[1] < b[1]) {
|
||||
return -1;
|
||||
}
|
||||
else {
|
||||
return 1;
|
||||
}
|
||||
}));
|
||||
|
||||
// Start Commit Checking
|
||||
let validString = '';
|
||||
|
@ -204,7 +220,7 @@ module.exports = {
|
|||
if (validDays.includes(formattedDay)) {
|
||||
dayMap.set(formattedDay, true);
|
||||
}
|
||||
else if (formattedDay != (monthName + ' ' + (new Date()).getDate().toString().padStart(2, 0))) {
|
||||
else if (formattedDay != (monthName + ' ' + (new Date()).getDate().toString())) {
|
||||
invalidString += `${formattedDay}\n`;
|
||||
dayMap.set(formattedDay, false);
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue