diff --git a/inc/theme-article.php b/inc/theme-article.php index 27debdf..e08c6bb 100644 --- a/inc/theme-article.php +++ b/inc/theme-article.php @@ -3,7 +3,7 @@ * 文章相关函数 * @author Seaton Jiang * @license MIT License - * @version 2020.06.13 + * @version 2020.10.26 */ // 文章链接添加 target 和 rel @@ -365,6 +365,9 @@ if (!kratos_option('g_gutenberg',false)) { { wp_dequeue_style('wp-block-library'); } + + // 禁用 Auto Embeds + remove_filter('the_content', array($GLOBALS['wp_embed'], 'autoembed'), 8); } // 文章评论增强 diff --git a/inc/theme-core.php b/inc/theme-core.php index 0ba4d99..47987ca 100644 --- a/inc/theme-core.php +++ b/inc/theme-core.php @@ -3,7 +3,7 @@ * 核心函数 * @author Seaton Jiang * @license MIT License - * @version 2020.08.04 + * @version 2020.10.26 */ if (kratos_option('g_cdn', false)) { @@ -163,9 +163,6 @@ add_filter('style_loader_src', function ($href) { return false; }); -// 禁用 Auto Embeds -remove_filter('the_content', array($GLOBALS['wp_embed'], 'autoembed'), 8); - // 替换国内 Gravatar 源 function get_https_avatar($avatar) {