Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bugfix/dst available hour mismatch #4909

Merged
merged 4 commits into from
Oct 7, 2022
Merged

Conversation

emrysal
Copy link
Contributor

@emrysal emrysal commented Oct 7, 2022

What does this PR do?

Aims to fix the hour discrepancy going into DST - tries to use the selected invitee date (with tz) and use the current day tz offset to properly display the booking slots.

@vercel
Copy link

vercel bot commented Oct 7, 2022

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Updated
cal ✅ Ready (Inspect) Visit Preview Oct 7, 2022 at 6:39PM (UTC)

Copy link
Member

@zomars zomars left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Some legibility concerns. We might need to spice up our code-commenting game

const startOfDayUTC = dayjs.utc().startOf("day");
const startOfDayUTC = dayjs.utc().set("hour", 0).set("minute", 0).set("second", 0);
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

why?


// eslint-disable-next-line @typescript-eslint/no-explicit-any
const timeZone: string = (inviteeDate as any)["$x"]["$timezone"];

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What is this?

Copy link
Member

@zomars zomars left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Perfect explanation @emrysal

Ship it

@zomars zomars merged commit ab62fc5 into main Oct 7, 2022
@zomars zomars deleted the bugfix/dst-available-hour-mismatch branch October 7, 2022 22:10
@PeerRich PeerRich added the core area: core, team members only label Jul 24, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
core area: core, team members only
Projects
No open projects
Status: Done
Development

Successfully merging this pull request may close these issues.

None yet

3 participants