plus server month calendar bug fix

This commit is contained in:
Sendou
2020-07-01 20:58:33 +03:00
parent 80c064c3f2
commit 23206e8cd0

View File

@@ -25,7 +25,7 @@ import { USER } from "../../graphql/queries/user"
const getFirstFridayDate = () => {
const today = new Date()
const month =
today.getDate() < 7 && today.getDay() > 5
today.getDate() <= 7 && today.getDay() <= 5
? today.getMonth()
: today.getMonth() + 1
@@ -124,10 +124,6 @@ const CalendarPage: React.FC<RouteComponentProps> = () => {
const thisMonth = time.getMonth()
const printWeekHeader = weekNumber !== lastPrintedWeek
/*const isFriday = time.getDay() === 5
const isFirstFridayOfTheMonth = isFriday && thisDay <= 7
const displayPlusServerVotingInfo = isPlusServerMember && isFirstFridayOfTheMonth*/
const printDayHeader =
thisDay !== lastPrintedDay || thisMonth !== lastPrintedMonth
if (printWeekHeader) {