Opened 2 years ago
Closed 2 years ago
#58400 closed defect (bug) (wontfix)
Current version should comes from variable or constant only.
Reported by: |
|
Owned by: | |
---|---|---|---|
Milestone: | Priority: | normal | |
Severity: | normal | Version: | |
Component: | Help/About | Keywords: | has-screenshots close |
Focuses: | coding-standards | Cc: |
Description
In the repository from WordPress is being downloaded there is static version number used. In wp-admin/about.php there are 2 places where static version number is used. We should use variable to define that in the same file $display_version is already used to define current version. Please see below 2 lines where static version number is used. I have attached screenshot as well please look on that.
Note: This is of https://build.trac.wordpress.org. Please let me know if I need to create ticket somewhere else.
https://build.trac.wordpress.org/browser/branches/6.2/wp-admin/about.php#L68
https://build.trac.wordpress.org/browser/branches/6.2/wp-admin/about.php#L68
Attachments (1)
Change History (3)
#1
@
2 years ago
- Component changed from Administration to Help/About
- Keywords close added; needs-patch removed
#2
@
2 years ago
- Milestone Awaiting Review deleted
- Resolution set to wontfix
- Status changed from new to closed
- Version 6.2.2 deleted
Thanks for the ticket and patch proposal,
However, let's resolve it as wontfix
as per the above comment: there's no value in making this a non static string. Feel free to reopen the ticket if you have any objection :)
Hi there, welcome back to WordPress Trac! Thanks for the ticket.
When looking at the file as a whole, you may find that
$display_version
is used in strings like:Welcome to WordPress %s
Learn more about WordPress %s
However, maintenance and security release entries (see 6.2.1 for example) use a hardcoded version number. Using
$display_version
there does not seem to provide any benefits, and would only add more work for the release team, as it would no longer be accurate for the previous release once a new one is available, so it would have to be replaced each time for a new release, and might be easy to miss.