Skip to content

Commit

Permalink
Remove unnecessary IsAuthenticated permission classses
Browse files Browse the repository at this point in the history
  • Loading branch information
Oksamies committed Jun 24, 2024
1 parent 3b90bf8 commit c650463
Show file tree
Hide file tree
Showing 4 changed files with 0 additions and 13 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@
from django.core.exceptions import ObjectDoesNotExist
from django.core.files.uploadedfile import TemporaryUploadedFile
from drf_yasg.utils import swagger_auto_schema
from rest_framework import permissions
from rest_framework.exceptions import NotFound, ValidationError
from rest_framework.response import Response
from rest_framework.views import APIView
Expand Down Expand Up @@ -36,8 +35,6 @@ class SubmitPackageApiView(APIView):
Submits a pre-uploaded package by upload uuid.
"""

permission_classes = [permissions.IsAuthenticated]

@swagger_auto_schema(
request_body=PackageSubmissionMetadataSerializer(),
responses={200: PackageSubmissionResult()},
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
from drf_yasg.utils import swagger_auto_schema
from rest_framework import permissions
from rest_framework.parsers import MultiPartParser
from rest_framework.response import Response
from rest_framework.views import APIView
Expand All @@ -17,7 +16,6 @@ class UploadPackageApiView(APIView):
"""

parser_classes = [MultiPartParser]
permission_classes = [permissions.IsAuthenticated]

@swagger_auto_schema(
deprecated=True,
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
from drf_yasg.utils import swagger_auto_schema
from rest_framework import permissions
from rest_framework.response import Response
from rest_framework.views import APIView

Expand All @@ -20,7 +19,6 @@ class ReadmeValidatorApiView(APIView):
Validates a package readme.
"""

permission_classes = [permissions.IsAuthenticated]
params_serializer_class = ReadmeValidatorParamsSerializer
response_serializer_class = ValidatorResponseSerializer

Expand Down Expand Up @@ -49,7 +47,6 @@ class ManifestV1ValidatorApiView(APIView):
Validates a package manifest.
"""

permission_classes = [permissions.IsAuthenticated]
params_serializer_class = ManifestV1ValidatorParamsSerializer
response_serializer_class = ValidatorResponseSerializer

Expand Down Expand Up @@ -83,7 +80,6 @@ class IconValidatorApiView(APIView):
Validates a package icon.
"""

permission_classes = [permissions.IsAuthenticated]
params_serializer_class = IconValidatorParamsSerializer
response_serializer_class = ValidatorResponseSerializer

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@
from drf_yasg.utils import swagger_auto_schema
from rest_framework import status
from rest_framework.generics import GenericAPIView
from rest_framework.permissions import IsAuthenticated
from rest_framework.response import Response

from thunderstore.usermedia.api.experimental.serializers import (
Expand All @@ -27,7 +26,6 @@
class UserMediaInitiateUploadApiView(GenericAPIView):
queryset = UserMedia.objects.active()
serializer_class = UserMediaInitiateUploadResponseSerializer
permission_classes = [IsAuthenticated]

@swagger_auto_schema(
request_body=UserMediaInitiateUploadParams,
Expand Down Expand Up @@ -72,7 +70,6 @@ class UserMediaFinishUploadApiView(GenericAPIView):
lookup_field = "uuid"
lookup_url_kwarg = "uuid"
serializer_class = UserMediaFinishUploadParamsSerializer
permission_classes = [IsAuthenticated]

@swagger_auto_schema(
request_body=UserMediaFinishUploadParamsSerializer(),
Expand Down Expand Up @@ -104,7 +101,6 @@ class UserMediaAbortUploadApiView(GenericAPIView):
queryset = UserMedia.objects.active()
lookup_field = "uuid"
lookup_url_kwarg = "uuid"
permission_classes = [IsAuthenticated]

@swagger_auto_schema(
responses={200: UserMediaSerializer()},
Expand Down

0 comments on commit c650463

Please sign in to comment.