Commit f7252e98 authored by Elias Sagmo Larsen's avatar Elias Sagmo Larsen
Browse files

pylint/unusedimport&toolongline

parent 0fc87444
Pipeline #127142 passed with stage
in 34 seconds
from rest_framework import generics, mixins
from rest_framework import permissions
from rest_framework.filters import OrderingFilter
from django.db.models import Q
from comments.models import Comment, Like
from comments.permissions import IsCommentVisibleToUser
from comments.serializers import CommentSerializer
......@@ -42,7 +41,9 @@ class CommentList(
if workout_pk:
queryset = Comment.objects.filter(workout=workout_pk)
elif self.request.user:
queryset = Comment.objects.filter(IsCommentVisibleToUser.has_object_permission).distinct()
queryset = Comment.objects.filter(
IsCommentVisibleToUser.has_object_permission
).distinct()
return queryset
......
# Generated by Django 3.1 on 2021-04-07 17:51
from django.db import migrations, models
class Migration(migrations.Migration):
dependencies = [
('facilities', '0003_auto_20210308_1733'),
]
operations = [
migrations.AlterField(
model_name='facility',
name='image2',
field=models.CharField(blank=True, max_length=2048),
),
migrations.AlterField(
model_name='facility',
name='image3',
field=models.CharField(blank=True, max_length=2048),
),
migrations.AlterField(
model_name='facility',
name='image4',
field=models.CharField(blank=True, max_length=2048),
),
migrations.AlterField(
model_name='facility',
name='image5',
field=models.CharField(blank=True, max_length=2048),
),
]
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment