#61862 closed defect (bug) (fixed)
Redundant code and potential inaccurate check in script-loader.php
Reported by: |
|
Owned by: |
|
---|---|---|---|
Milestone: | 6.7 | Priority: | normal |
Severity: | normal | Version: | 5.1 |
Component: | Script Loader | Keywords: | has-patch |
Focuses: | Cc: |
Description (last modified by )
Since [44651] removed the build steps for a gzipped version of TinyMCE that has remained code in script-loader.php
that checks if gzip is supported on the server, these checks are redundant and superfluous.
They may also result in the uncompressed files being used when the compressed files are available and could be used.
$compressed = $compress_scripts && $concatenate_scripts && isset( $_SERVER['HTTP_ACCEPT_ENCODING'] )
&& false !== stripos( $_SERVER['HTTP_ACCEPT_ENCODING'], 'gzip' ) && ! $force_uncompressed;
can are replaced with:
$compressed = $compress_scripts && $concatenate_scripts && ! $force_uncompressed;
The documentation further down may also need updating.
Change History (9)
This ticket was mentioned in PR #7191 on WordPress/wordpress-develop by @hbhalodia.
5 months ago
#1
- Keywords has-patch added
#4
@
5 months ago
@hbhalodia - patch looks good but inline documentation further down still references wp-tinymce.js.gz
so that many also need adjusting.
#6
@
5 months ago
Hi @MattyRob @SergeyBiryukov, I have updated the inline documentation to not reference the gz
. Can you please take a look if that is needs to be updated?
Thank You,
#8
@
5 months ago
- Owner set to SergeyBiryukov
- Resolution set to fixed
- Status changed from new to closed
In 58902:
@SergeyBiryukov commented on PR #7191:
5 months ago
#9
Thanks for the PR! Merged in r58902.
Trac ticket: https://core.trac.wordpress.org/ticket/61862