@@ -11,7 +11,7 @@ discard block |
||
11 | 11 | |
12 | 12 | define(__NAMESPACE__ . '\NS', __NAMESPACE__ . '\\'); |
13 | 13 | |
14 | -add_action('Flynt/afterRegisterComponents', function () { |
|
14 | +add_action('Flynt/afterRegisterComponents', function() { |
|
15 | 15 | if (((defined('WP_ENV') && WP_ENV === 'development') || current_user_can('editor') || current_user_can('administrator')) && isset($_GET['log'])) { |
16 | 16 | if (isset($_GET['component']) && !empty($_GET['component'])) { |
17 | 17 | define(__NAMESPACE__ . '\COMPONENT_WHITELIST', explode(',', $_GET['component'])); |
@@ -38,21 +38,21 @@ discard block |
||
38 | 38 | { |
39 | 39 | $type = gettype($data); |
40 | 40 | $output = json_encode($data); |
41 | - $result = "<script>console.log({$output});</script>\n"; |
|
41 | + $result = "<script>console.log({$output});</script>\n"; |
|
42 | 42 | echoDebug($result, $postpone); |
43 | 43 | } |
44 | 44 | |
45 | 45 | function consoleTable($data, $postpone = true) |
46 | 46 | { |
47 | 47 | $output = json_encode($data); |
48 | - $result = "<script>console.table({$output});</script>\n"; |
|
48 | + $result = "<script>console.table({$output});</script>\n"; |
|
49 | 49 | echoDebug($result, $postpone); |
50 | 50 | } |
51 | 51 | |
52 | 52 | function echoDebug($data, $postpone) |
53 | 53 | { |
54 | 54 | if ($postpone) { |
55 | - add_action('wp_footer', function () use ($data) { |
|
55 | + add_action('wp_footer', function() use ($data) { |
|
56 | 56 | echo $data; |
57 | 57 | }, 30); |
58 | 58 | } else { |