From 137f55e4cede35bf17a8b9a8e8e8ccbcc2f7d87e Mon Sep 17 00:00:00 2001 From: Ivan Nieto Vivanco Date: Wed, 25 Aug 2021 15:27:25 -0500 Subject: [PATCH] Change condition to return the actual max upload size allowed to files --- app/Helpers/Helper.php | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/app/Helpers/Helper.php b/app/Helpers/Helper.php index 0cba900920..d331ea36f5 100644 --- a/app/Helpers/Helper.php +++ b/app/Helpers/Helper.php @@ -890,7 +890,8 @@ class Helper // If upload_max_size is less, then reduce. Except if upload_max_size is // zero, which indicates no limit. $upload_max = Helper::parse_size(ini_get('upload_max_filesize')); - if ($upload_max > 0 && $upload_max < $max_size) { + + if ($upload_max > 0 && $upload_max < $post_max_size) { $max_size = ini_get('upload_max_filesize'); } }