if "*" in TODO_LIMIT_FILE_ATTACHMENTS, allow all
This commit is contained in:
parent
21e0c6d656
commit
d41d9887af
1 changed files with 1 additions and 1 deletions
|
@ -127,7 +127,7 @@ def task_detail(request, task_id: int) -> HttpResponse:
|
|||
|
||||
name, extension = os.path.splitext(file.name)
|
||||
|
||||
if extension not in defaults("TODO_LIMIT_FILE_ATTACHMENTS"):
|
||||
if extension not in defaults("TODO_LIMIT_FILE_ATTACHMENTS") and "*" not in defaults("TODO_LIMIT_FILE_ATTACHMENTS"):
|
||||
messages.error(request, f"This site does not allow upload of {extension} files.")
|
||||
return redirect("todo:task_detail", task_id=task.id)
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue