From 9cb1edfa496711f5efeffad6cfb09924e90efea8 Mon Sep 17 00:00:00 2001 From: xiaochong0302 Date: Fri, 2 Feb 2024 20:58:22 +0800 Subject: [PATCH] =?UTF-8?q?1.=E4=BF=AE=E6=AD=A3home=E6=A8=A1=E5=9D=97?= =?UTF-8?q?=E7=BC=96=E8=BE=91=E5=99=A8=E5=9B=BE=E7=89=87=E4=B8=8A=E4=BC=A0?= =?UTF-8?q?=202.=E7=B2=BE=E7=AE=80CsrfToken=E7=99=BD=E5=90=8D=E5=8D=95?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- CHANGELOG.md | 1 - app/Library/AppInfo.php | 2 +- app/Services/EditorStorage.php | 2 +- app/Validators/Security.php | 2 -- public/static/home/js/content.editor.js | 2 +- 5 files changed, 3 insertions(+), 6 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index ab925848..71fcadee 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -14,7 +14,6 @@ - 优化AccountTrait - 优化错误处理 - ### [v1.6.7](https://gitee.com/koogua/course-tencent-cloud/releases/v1.6.7)(2023-12-15) - 增加文章分类功能 diff --git a/app/Library/AppInfo.php b/app/Library/AppInfo.php index 72fadf97..3a8f3414 100644 --- a/app/Library/AppInfo.php +++ b/app/Library/AppInfo.php @@ -16,7 +16,7 @@ class AppInfo protected $link = 'https://www.koogua.com'; - protected $version = '1.6.8'; + protected $version = '1.6.9'; public function __get($name) { diff --git a/app/Services/EditorStorage.php b/app/Services/EditorStorage.php index 10fb488d..47e1cd81 100644 --- a/app/Services/EditorStorage.php +++ b/app/Services/EditorStorage.php @@ -151,7 +151,7 @@ class EditorStorage extends Storage { $path = parse_url($imageUrl, PHP_URL_PATH); - preg_match('/(\S+)\.(png|gif|jpg|jpeg)/i', $path, $matches); + preg_match('/(\S+)\.(png|gif|jpg|jpeg|webp)/i', $path, $matches); return $matches[2] ? strtolower($matches[2]) : 'jpg'; } diff --git a/app/Validators/Security.php b/app/Validators/Security.php index 8387fc49..049f454c 100644 --- a/app/Validators/Security.php +++ b/app/Validators/Security.php @@ -60,9 +60,7 @@ class Security extends Validator { return [ 'admin.upload.content_img', - 'admin.upload.remote_img', 'home.upload.content_img', - 'home.upload.remote_img', ]; } diff --git a/public/static/home/js/content.editor.js b/public/static/home/js/content.editor.js index c7c57b45..254b75b6 100644 --- a/public/static/home/js/content.editor.js +++ b/public/static/home/js/content.editor.js @@ -5,7 +5,7 @@ layui.use(['jquery'], function () { var editor; var options = { - uploadJson: '/admin/upload/content/img', + uploadJson: '/upload/content/img', cssPath: '/static/home/css/content.css', width: '100%', height: '300px',