Basically, I want to filter out inactive users from a related field of a ModelSerializer. I tried [Dynamically limiting queryset of related field](https://stackoverflow.com/questions/15328632/dynamically-limiting-queryset-of-related-field) as well as the following:

```
class MySerializer(serializers.ModelSerializer):
  users = serializers.PrimaryKeyRelatedField(queryset=User.objects.filter(active=True), many=True)
  class Meta:
    model = MyModel
    fields = ('users',)

```

Neither of these approaches worked for just filtering the queryset. I want to do this for a nested related Serializer class as a field (but couldn't even get it to work with a RelatedField).

How do I filter queryset for nested relation?