#48267 closed defect (bug) (fixed)
IXR: Use spread args (was Modernize IXR library)
Reported by: | kraftbj | Owned by: | |
---|---|---|---|
Milestone: | 5.5 | Priority: | normal |
Severity: | normal | Version: | |
Component: | XML-RPC | Keywords: | has-dev-note |
Focuses: | Cc: |
Description
Motivated by #47678, I started updating func_get_args
calls in a plugin that extended the IXR classes provided by Core and realized that I was getting ahead of myself and Core.
With this coming from a seemingly abandoned upstream library where we haven't modernize the code in some time, before doing more (PHPCS, inline docs, etc), what is the status of this part of the code? Open to being modernized?
Attaching a simple patch for the spread operator to start the discussion.
Subtasks:
- Remove PHP 4 and pre-PHP 5.6 conventions.
- PHPCS.
- Inline documentation.
Related: #46484
Attachments (3)
Change History (16)
#2
in reply to:
↑ description
@
5 years ago
Replying to kraftbj:
With this coming from a seemingly abandoned upstream library where we haven't modernize the code in some time, before doing more (PHPCS, inline docs, etc), what is the status of this part of the code? Open to being modernized?
Looking at the recent commits, of which [38389] is probably the most substantial:
- https://core.trac.wordpress.org/log/trunk/src/wp-includes/IXR
- https://core.trac.wordpress.org/log/trunk/src/wp-includes/class-IXR.php
it appears to be treated as "adopted" rather than external, so I think we should bring it in line with the rest of core.
#3
@
5 years ago
- Milestone changed from 5.4 to Future Release
Hi,
With 5.4 Beta 3 approaching and the Beta period reserved for bugs introduced during the cycle, this is being moved to Future Release. If any maintainer or committer feels this should be included or wishes to assume ownership during a specific cycle, feel free to update the milestone accordingly.
#6
@
4 years ago
- Keywords needs-dev-note added
[48204] should be mentioned in a dev note.
Keeping the ticket open for now to address the other subtasks from the description.
#7
@
4 years ago
Please note that this breaks PHP 8 builds because PHP 8 enforce strict LSP checks: https://php.watch/versions/8.0/lsp-errors
Build: https://travis-ci.com/github/Ayesh/wordpress-develop/jobs/355902441#L2647
In versions prior to PHP 8, this change still raises a warning, so I think this needs to be fixed before 5.5 even though we target 5.6 for PHP 8.
This ticket was mentioned in Slack in #core by ayesh. View the logs.
4 years ago
#11
@
4 years ago
- Resolution set to fixed
- Status changed from new to closed
I am in the process of drafting the dev note and just confirmed this is in the list of notes being tracked by the release squad. Going to close this out to help clear the milestone in advance of beta 1 tomorrow.
#12
@
4 years ago
- Summary changed from IXR: Modernize IXR library to IXR: Use spread args (was Modernize IXR library)
Thanks @desrosj. I'll open up a new ticket to track more specific pieces of this to save the need to juggle tickets moving forward.
#13
@
4 years ago
- Keywords has-dev-note added; needs-dev-note removed
Referenced in the following dev note: https://make.wordpress.org/core/2020/07/14/php-related-improvements-changes-wordpress-5-5-edition/.
Add spread operator