Skip to content

Commit

Permalink
Linting - instead of os.path.join, use pathlib.Path
Browse files Browse the repository at this point in the history
  • Loading branch information
fritzbrand committed Sep 5, 2023
1 parent c53ea1b commit 5dbe18c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion home/whatsapp.py
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ def get_upload_session_id(image_id):
img_obj = get_image_model().objects.get(id=image_id)
mime_type = mimetypes.guess_type(img_obj.file.name)[0]
file_size = img_obj.file.size
file_path = os.path.join(settings.MEDIA_ROOT, img_obj.file.name)
file_path = Path(settings.MEDIA_ROOT) / img_obj.file.name
data = {
"file_length": file_size,
"file_type": mime_type,
Expand Down

0 comments on commit 5dbe18c

Please sign in to comment.