Skip to content

Commit ca24d8b

Browse files
committed
zero padding
1 parent 135648b commit ca24d8b

File tree

1 file changed

+1
-1
lines changed
  • Matrix_Portal_S3_ESPN_API/CircuitPython

1 file changed

+1
-1
lines changed

Matrix_Portal_S3_ESPN_API/CircuitPython/code.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -174,7 +174,7 @@ def convert_date_format(date, tz_information):
174174
# Convert 24-hour format to 12-hour format and determine AM/PM
175175
am_pm = "AM" if hour < 12 else "PM"
176176
hour_12 = hour if hour <= 12 else hour - 12
177-
minute = minute if minute >= 10 else f"0{minute}"
177+
minute = f"{minute:02}"
178178
# Determine the timezone abbreviation based on the offset
179179
time_zone_str = tz_information[1]
180180
return f"{month}/{day} - {hour_12}:{minute} {am_pm} {time_zone_str}"

0 commit comments

Comments
 (0)