| @@ -16,15 +16,17 @@ | ||
| 16 | 16 | if (empty(self::$messages)) { |
| 17 | 17 | return; |
| 18 | 18 | } |
| 19 | 19 | |
| 20 | - $o = 'console.group("[PhastPress] Plugin compatibility");'; | |
| 20 | + $o = '<script data-phast-no-defer>'; | |
| 21 | + $o .= 'console.group("[PhastPress] Plugin compatibility");'; | |
| 21 | 22 | foreach (self::$messages as $plugin => $messages) { |
| 22 | 23 | foreach ($messages as $message) { |
| 23 | - $o .= 'console.log(' . json_encode($plugin ? "{$plugin}: {$message}" : $message) . ');'; | |
| 24 | + $o .= 'console.log(' . json_encode("{$plugin}: {$message}") . ');'; | |
| 24 | 25 | } |
| 25 | 26 | } |
| 26 | 27 | $o .= 'console.groupEnd();'; |
| 28 | + $o .= '</script>'; | |
| 27 | 29 | |
| 28 | - echo phastpress_script($o, ['data-phast-no-defer' => '']); | |
| 30 | + echo $o; | |
| 29 | 31 | } |
| 30 | 32 | } |