Fixes: 1) Ensure encoded_uuid is cast to string before decoding to avoid potential errors;
Extra: None;
This commit is contained in:
parent
25b1064c37
commit
7f8ab0de88
1 changed files with 1 additions and 1 deletions
|
|
@ -468,7 +468,7 @@ def download_digital_asset_view(request, *args, **kwargs):
|
||||||
a JsonResponse with an error message if an error occurs during the process.
|
a JsonResponse with an error message if an error occurs during the process.
|
||||||
"""
|
"""
|
||||||
try:
|
try:
|
||||||
uuid = force_str(urlsafe_base64_decode(kwargs.get("encoded_uuid")))
|
uuid = force_str(urlsafe_base64_decode(str(kwargs.get("encoded_uuid"))))
|
||||||
download = DigitalAssetDownload.objects.get(order_product__uuid=uuid)
|
download = DigitalAssetDownload.objects.get(order_product__uuid=uuid)
|
||||||
|
|
||||||
if download.num_downloads >= 1:
|
if download.num_downloads >= 1:
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue