Skip to content

Commit a2d6d49

Browse files
CopilotProLoser
andcommitted
Address code review feedback - eliminate variable shadowing
Co-authored-by: ProLoser <67395+ProLoser@users.noreply.github.com>
1 parent 546e977 commit a2d6d49

1 file changed

Lines changed: 1 addition & 2 deletions

File tree

19hz/map.js

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -614,8 +614,7 @@ class Events {
614614
let end;
615615
if (time[1]) {
616616
const endTime = Events.parseTime12Hour(time[1]);
617-
// Parse date string as local date to avoid timezone issues
618-
const [year, month, day] = event.date.split('-').map(Number);
617+
// Reuse parsed date components from start date
619618
end = new Date(year, month - 1, day);
620619
end.setHours(endTime.hours, endTime.minutes, 0, 0);
621620

0 commit comments

Comments
 (0)