This commit is contained in:
Aevann1 2021-10-03 21:36:29 +02:00
parent 00b18ca1dc
commit 4dab5b9050
5 changed files with 9 additions and 9 deletions

View file

@ -123,7 +123,7 @@ def post_pid_comment_cid(cid, pid=None, anything=None, v=None):
@is_not_banned
@validate_formkey
def api_comment(v):
if request.content_length > 16 * 1024 * 1024: abort(413)
if request.content_length > 4 * 1024 * 1024: return "Max file size is 4 MB.", 413
parent_submission = request.values.get("submission")
parent_fullname = request.values.get("parent_fullname")
@ -586,7 +586,7 @@ def api_comment(v):
@auth_required
@validate_formkey
def edit_comment(cid, v):
if request.content_length > 16 * 1024 * 1024: abort(413)
if request.content_length > 4 * 1024 * 1024: return "Max file size is 4 MB.", 413
c = get_comment(cid, v=v)