Skip to content

Commit 31d53f8

Browse files
Script Loader: Remove redundant check in wp_register_tinymce_scripts().
Since removing the build steps for a gzipped version of TinyMCE, the check whether gzip is supported on the server is superfluous. It may also result in the uncompressed files being used when the compressed files are available and could be used. Follow-up to [44114], [44651]. Props MattyRob, hbhalodia. Fixes #61862. git-svn-id: https://develop.svn.wordpress.org/trunk@58902 602fd350-edb4-49c9-b593-d223f7449a82
1 parent efee925 commit 31d53f8

File tree

1 file changed

+2
-3
lines changed

1 file changed

+2
-3
lines changed

src/wp-includes/script-loader.php

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -54,11 +54,10 @@ function wp_register_tinymce_scripts( $scripts, $force_uncompressed = false ) {
5454

5555
script_concat_settings();
5656

57-
$compressed = $compress_scripts && $concatenate_scripts && isset( $_SERVER['HTTP_ACCEPT_ENCODING'] )
58-
&& false !== stripos( $_SERVER['HTTP_ACCEPT_ENCODING'], 'gzip' ) && ! $force_uncompressed;
57+
$compressed = $compress_scripts && $concatenate_scripts && ! $force_uncompressed;
5958

6059
/*
61-
* Load tinymce.js when running from /src, otherwise load wp-tinymce.js.gz (in production)
60+
* Load tinymce.js when running from /src, otherwise load wp-tinymce.js (in production)
6261
* or tinymce.min.js (when SCRIPT_DEBUG is true).
6362
*/
6463
if ( $compressed ) {

0 commit comments

Comments
 (0)