Completed
Pull Request — master (#210)
by
unknown
04:22
created
inc/cleanHead.php 1 patch
Spacing   +7 added lines, -7 removed lines patch added patch discarded remove patch
@@ -28,11 +28,11 @@  discard block
 block discarded – undo
28 28
  * Remove self-closing tag
29 29
  *
30 30
  */
31
-add_action('init', function () {
31
+add_action('init', function() {
32 32
     // Originally from http://wpengineer.com/1438/wordpress-header/
33 33
     remove_action('wp_head', 'feed_links_extra', 3);
34 34
     add_action('wp_head', 'ob_start', 1, 0);
35
-    add_action('wp_head', function () {
35
+    add_action('wp_head', function() {
36 36
         $pattern = '/.*' . preg_quote(esc_url(get_feed_link('comments_' . get_default_feed())), '/') . '.*[\r\n]+/';
37 37
         echo preg_replace($pattern, '', ob_get_clean());
38 38
     }, 3, 0);
@@ -58,16 +58,16 @@  discard block
 block discarded – undo
58 58
 /**
59 59
  * Remove id, class, type and media attributes from <link> tags.
60 60
  */
61
-\add_filter('style_loader_tag', function ($input) {
62
-    return \preg_replace( array( "#\s(id|class|type|media)='[^']+'#", '/\s{2,}/') , array('', ' ') , $input );
61
+\add_filter('style_loader_tag', function($input) {
62
+    return \preg_replace(array("#\s(id|class|type|media)='[^']+'#", '/\s{2,}/'), array('', ' '), $input);
63 63
 });
64 64
 
65 65
 /**
66 66
  * Remove type attribute from script tags if WordPress is lower than 5.3.
67 67
  */
68 68
 global $wp_version;
69
-if ( \version_compare($wp_version, '5.3', '<')) {
70
-    \add_filter('script_loader_tag', function ($input) {
71
-        return \preg_replace( array("#\s(type)='[^']+'#", '/\s{2,}/') , array('', ' ') , $input );
69
+if (\version_compare($wp_version, '5.3', '<')) {
70
+    \add_filter('script_loader_tag', function($input) {
71
+        return \preg_replace(array("#\s(type)='[^']+'#", '/\s{2,}/'), array('', ' '), $input);
72 72
     });
73 73
 }
Please login to merge, or discard this patch.
inc/theme.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -1,6 +1,6 @@  discard block
 block discarded – undo
1 1
 <?php
2 2
 
3
-add_action('after_setup_theme', function () {
3
+add_action('after_setup_theme', function() {
4 4
     add_theme_support('title-tag');
5 5
     add_theme_support('post-thumbnails');
6 6
 
@@ -8,7 +8,7 @@  discard block
 block discarded – undo
8 8
      * Remove type attribute from link and script tags.
9 9
      */
10 10
     global $wp_version;
11
-    if ( version_compare( $wp_version, '5.3', '>=' ) ) {
11
+    if (version_compare($wp_version, '5.3', '>=')) {
12 12
         add_theme_support('html5', array('script', 'style'));
13 13
     }
14 14
 });
Please login to merge, or discard this patch.