#53937 closed defect (bug) (wontfix)
delete the un-used function _upgrade_cron_array()
Reported by: | pbearne | Owned by: | |
---|---|---|---|
Milestone: | Priority: | normal | |
Severity: | normal | Version: | 5.9 |
Component: | Cron API | Keywords: | has-patch |
Focuses: | Cc: |
Description
This function was added in 2.1.0 to modify the shape of the cron array stored in the options table _upgrade_cron_array
As we are on version 5.8 it is very unlikely that it is ever run.
So let remove it from the codebase
Change History (5)
This ticket was mentioned in PR #1593 on WordPress/wordpress-develop by pbearne.
3 years ago
#2
- Keywords has-patch added
Removed unused function _upgrade_cron_array()
Trac ticket: https://core.trac.wordpress.org/ticket/53937
#3
follow-up:
↓ 4
@
3 years ago
Thanks for the ticket!
I think we should not remove the version
field from _set_cron_array()
though, as that would block us from changing the option structure in the future.
We should also consider what happens with the cron
option if someone does upgrade from WordPress < 2.1 to the current version, which is still a possibility, as unlikely as it may be. I see no harm in keeping the function in place if it helps avoid some obscure bugs in that scenario.
#4
in reply to:
↑ 3
@
3 years ago
- Milestone Awaiting Review deleted
- Resolution set to wontfix
- Status changed from new to closed
Replying to SergeyBiryukov:
I think we should not remove the
version
field from_set_cron_array()
though, as that would block us from changing the option structure in the future.
I agree with Sergey's view here, both in terms of allow for future format changes and allowing for very old installs to update. It's also a pretty harmless function to keep around.
Ticket #34913 contains a patch that proposes upgrading the cron array format to version 3 within _upgrade_cron_array()
so it may happen at some point.
I'm going to close this ticket as wontfix but thank you for taking an interest in the cron component. It's great to see it getting some attention.
@peterwilsoncc commented on PR #1593:
13 months ago
#5
WP#53937 was closed as wontfix so closing this PR off.
We could also drop the Version 2 test