Skip to content

Scheduling infrastructure for absolutely everyone.

Fix missing zero-padding on troubleshoot (#1974)

Leo Giovanetti546f6271773d
diff --git a/apps/web/pages/availability/troubleshoot.tsx b/apps/web/pages/availability/troubleshoot.tsx
index 85c308856b9..eeb76a1bd95 100644
--- a/apps/web/pages/availability/troubleshoot.tsx
+++ b/apps/web/pages/availability/troubleshoot.tsx
@@ -22,9 +22,9 @@ const AvailabilityView = ({ user }: { user: User }) => {
function convertMinsToHrsMins(mins: number) {
let h = Math.floor(mins / 60);
let m = mins % 60;
- h = h < 10 ? 0 + h : h;
- m = m < 10 ? 0 + m : m;
- return `${h}:${m}`;
+ let hs = h < 10 ? "0" + h : h;
+ let ms = m < 10 ? "0" + m : m;
+ return `${hs}:${ms}`;
}
useEffect(() => {