@classmethod
    def apply_filter(cls, request, *args):
        args = list(args)
        if not request.user.is_staff:
            args.append(models.Q(author=request.user.id) | models.Q(status=cls.PUBLISHED))
        return cls.objects.filter(*args)
Creating a registration profile for a user populates the
dataset/ETHPy150Open 2buntu/2buntu-blog/twobuntu/articles/models.py/Article.apply_filter--crossover with--dataset/ETHPy150Open macropin/django-registration/registration/tests/models.py/RegistrationModelTests.test_profile_creation