Skip to content

Commit

Permalink
Fix code style
Browse files Browse the repository at this point in the history
  • Loading branch information
Kateryna Zadorozhna committed Oct 10, 2023
1 parent bc3b34c commit 186bf55
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 3 deletions.
4 changes: 3 additions & 1 deletion cinema/urls.py
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,9 @@
path("actors/", ActorList.as_view(), name="actor-list"),
path("actors/<int:pk>/", ActorDetail.as_view(), name="actor-detail"),
path("cinema_halls/", cinema_hall_list, name="cinema_hall-list"),
path("cinema_halls/<int:pk>/", cinema_hall_detail, name="cinema_hall-detail"),
path(
"cinema_halls/<int:pk>/", cinema_hall_detail, name="cinema_hall-detail"
),
path("genres/", GenreList.as_view(), name="genre-list"),
path("genres/<int:pk>/", GenreDetail.as_view(), name="genre-detail"),
path("", include(router.urls)),
Expand Down
8 changes: 6 additions & 2 deletions cinema/views.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,12 @@
from rest_framework.views import APIView

from cinema.models import Movie, Genre, Actor, CinemaHall
from cinema.serializers import MovieSerializer, GenreSerializer, ActorSerializer, CinemaHallSerializer
from cinema.serializers import (
ActorSerializer,
CinemaHallSerializer,
GenreSerializer,
MovieSerializer
)


class MovieViewSet(viewsets.ModelViewSet):
Expand Down Expand Up @@ -76,4 +81,3 @@ def delete(self, request, pk):
genre = self.get_object(pk)
genre.delete()
return Response(status=status.HTTP_204_NO_CONTENT)

0 comments on commit 186bf55

Please sign in to comment.