Skip to content

Commit 68b6153

Browse files
committed
no useless error handeling in
1 parent f7786ce commit 68b6153

1 file changed

Lines changed: 2 additions & 5 deletions

File tree

users/views.py

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -470,8 +470,6 @@ def post(self, request, *args, **kwargs):
470470
return Response(
471471
"User with given email does not exists!", status=status.HTTP_404_NOT_FOUND
472472
)
473-
except Exception:
474-
return Response(status=status.HTTP_400_BAD_REQUEST)
475473

476474

477475
class ForceVerifyView(APIView):
@@ -614,9 +612,7 @@ def get(self, request, *args, **kwargs) -> HttpResponse:
614612
data_preparer = UserCVDataPreparerV2(request.user.pk)
615613
user_cv_data: UserCVDataV2 = data_preparer.get_prepared_data()
616614

617-
html_string: str = render_to_string(
618-
data_preparer.TEMPLATE_PATH, user_cv_data
619-
)
615+
html_string: str = render_to_string(data_preparer.TEMPLATE_PATH, user_cv_data)
620616
binary_pdf_file: bytes | None = HTML(string=html_string).write_pdf()
621617

622618
encoded_filename: str = urllib.parse.quote(
@@ -635,6 +631,7 @@ class UserCVMailing(APIView):
635631
Full-fledged work `UserCVDownload`.
636632
The user can send a letter once per minute.
637633
"""
634+
638635
permission_classes = [IsAuthenticated]
639636

640637
def get(self, request, *args, **kwargs):

0 commit comments

Comments
 (0)