'Custom filter method allowing us to filter on app slug/pk and user pk
(or the special user value "mine"). A full FilterSet is overkill here.'

def filter_queryset(self, queryset):

    filters = Q()
    app = self.request.GET.get('app')
    user = self.request.GET.get('user')
    lang = self.request.GET.get('lang')
    match_lang = self.request.GET.get('match_lang')
    if app:
        self.app = self.get_app(app)
        filters &= Q(addon=self.app)
    if user:
        filters &= Q(user=self.get_user(user))
    elif (lang and (match_lang == '1')):
        filters &= Q(lang=lang)
    if filters:
        queryset = queryset.filter(filters)
    return queryset
