I'm looking for a way to access the context to filter by current user
class RemovePermissionsSerializer(serializers.Serializer):
user_permissions = serializers.PrimaryKeyRelatedField(
many=True, queryset=Permission.objects.filter(user = context.get('request').user)
)
I can't access context becuase it's undefined, neither self.context