From 2a025e9ec9b85fbf3513c6cb6d629704c043463b Mon Sep 17 00:00:00 2001 From: Baoshuo Date: Wed, 16 Nov 2022 16:42:02 +0800 Subject: [PATCH] fix: d8d97b4f93900c418dec4e8aa315394e8bc893ef --- web/app/controllers/image_hosting/index.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/web/app/controllers/image_hosting/index.php b/web/app/controllers/image_hosting/index.php index 74a652a..c6c60dd 100644 --- a/web/app/controllers/image_hosting/index.php +++ b/web/app/controllers/image_hosting/index.php @@ -59,7 +59,7 @@ if ($_POST['image_upload_file_submit'] == 'submit') { list($width, $height, $type) = $size; $hash = hash_file("sha256", $_FILES['image_upload_file']['tmp_name']) . Auth::id(); - $scale = ceil($height / 600.0); + $scale = ceil($width / 600.0); $watermark_text = UOJConfig::$data['profile']['oj-name-short']; if (isSuperUser(Auth::user()) && $_POST['watermark'] == 'no_watermark') {