Skip to content

Commit

Permalink
fix max upload size (#6047)
Browse files Browse the repository at this point in the history
Co-authored-by: 孙永强 <[email protected]>
  • Loading branch information
awu0403 and 孙永强 committed May 1, 2024
1 parent 2a37732 commit 7793339
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions seahub/views/repo.py
Original file line number Diff line number Diff line change
Expand Up @@ -332,6 +332,12 @@ def view_shared_dir(request, fileshare):
# for 'upload file'
no_quota = True if seaserv.check_quota(repo_id) < 0 else False

try:
max_upload_file_size = seafile_api.get_server_config_int('fileserver', 'max_upload_size')
except Exception as e:
logger.error(e)
max_upload_file_size = -1

template = 'view_shared_dir_react.html'

dir_share_link = request.path
Expand All @@ -348,6 +354,7 @@ def view_shared_dir(request, fileshare):
'dir_list': dir_list,
'zipped': zipped,
'traffic_over_limit': False,
'max_upload_file_size': max_upload_file_size,
'no_quota': no_quota,
'permissions': permissions,
'mode': mode,
Expand Down

0 comments on commit 7793339

Please sign in to comment.