From c3250ee91630f14fe23c27d3be58dca576640b50 Mon Sep 17 00:00:00 2001 From: n0099 Date: Thu, 11 Mar 2021 08:05:05 +0800 Subject: [PATCH] fix: some plugin issues * fix: action comment_form_after should be called #341 * fix: add custom_upload_perfilter on filter wp_handle_sideload_prefilter #345 --- comments.php | 3 ++- inc/theme-core.php | 3 ++- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/comments.php b/comments.php index e670286..8a90d46 100644 --- a/comments.php +++ b/comments.php @@ -74,9 +74,10 @@ if (comments_open()) {?> + ID);?> - \ No newline at end of file + diff --git a/inc/theme-core.php b/inc/theme-core.php index 0387c9e..600fa2a 100644 --- a/inc/theme-core.php +++ b/inc/theme-core.php @@ -210,6 +210,7 @@ if (kratos_option('g_removeimgsize', false)) { } // 媒体文件使用 md5 值重命名,指定文件前缀 +add_filter('wp_handle_sideload_prefilter', 'custom_upload_perfilter'); add_filter('wp_handle_upload_prefilter', 'custom_upload_filter'); function custom_upload_filter($file) @@ -407,4 +408,4 @@ if (kratos_option('g_007', false)) { curl_close($ch); return $response; } -} \ No newline at end of file +}