Skip to content

Commit

Permalink
perf: support enable oss through config (#1485)
Browse files Browse the repository at this point in the history
Signed-off-by: yangk <[email protected]>
  • Loading branch information
yangkaa authored Jul 31, 2024
1 parent 8c0b5d8 commit 7b5158c
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion console/services/file_upload_service.py
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,8 @@ def is_upload_to_oss(self):
oss_config = ConsoleSysConfig.objects.filter(key='OSS_CONFIG').first()
if oss_config:
data = json.loads(oss_config.value)
return len(data) == 4
enable = data.get('enable', False)
return enable
return False

def upload_file_to_local(self, upload_file, suffix):
Expand Down

0 comments on commit 7b5158c

Please sign in to comment.