Opened 11 years ago
Closed 11 years ago
#34602 closed enhancement (fixed)
Use the new MONTH_IN_SECONDS constant in human_time_diff()
| Reported by: | tyxla | Owned by: | SergeyBiryukov |
|---|---|---|---|
| Priority: | normal | Milestone: | 4.4 |
| Component: | Formatting | Version: | 4.4 |
| Severity: | normal | Keywords: | has-patch |
| Cc: | Focuses: |
Description
#33397 introduces a new constant MONTH_IN_SECONDS, which is defined as 30 * DAY_IN_SECONDS.
The human_time_diff() function uses the month time in its logic as well, and it is also currently using a hardcoded 30 * DAY_IN_SECONDS value for months.
So for consistency we should replace all occurrences of 30 * DAY_IN_SECONDS to MONTH_IN_SECONDS in human_time_diff().
Attachments (1)
Change History (5)
Note:
See TracTickets
for help on using tickets.
![(please configure the [header_logo] section in trac.ini)](/chrome/site/your_project_logo.png)
Use the new
MONTH_IN_SECONDSconstant for the month representation in thehuman_time_diff()logic.