Skip to content

Commit

Permalink
Fix arguments in exception. (#67)
Browse files Browse the repository at this point in the history
## Изменения
Добавлена передача аргумента в конструктор объекта ошибки.

## Check-List
<!-- После сохранения у следующих полей появятся галочки, которые нужно
проставить мышкой -->
- [x] Вы проверили свой код перед отправкой запроса?
- [x] Вы написали тесты к реализованным функциям?
- [x] Вы не забыли применить форматирование `black` и `isort` для
_Back-End_ или `Prettier` для _Front-End_?
  • Loading branch information
Temmmmmo authored Oct 16, 2023
1 parent 5b6a4e5 commit 2e48ce5
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion print_service/routes/file.py
Original file line number Diff line number Diff line change
Expand Up @@ -179,7 +179,7 @@ async def upload_file(
await file.close()
raise PINNotFound(pin)
if file.content_type not in settings.CONTENT_TYPES:
raise InvalidType()
raise InvalidType(file.content_type)
path = abspath(settings.STATIC_FOLDER) + '/' + file_model.file
if exists(path):
await file.close()
Expand Down

0 comments on commit 2e48ce5

Please sign in to comment.