Skip to content

Commit

Permalink
Revert "Fixes: #14840 - Forces API to use proxy model"
Browse files Browse the repository at this point in the history
This reverts commit df85cc9.
  • Loading branch information
DanSheps committed Jan 24, 2024
1 parent 773daed commit 3ab8caa
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions netbox/users/api/views.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@

from netbox.api.viewsets import NetBoxModelViewSet
from users import filtersets
from users.models import ObjectPermission, Token, UserConfig, NetBoxUser
from users.models import ObjectPermission, Token, UserConfig
from utilities.querysets import RestrictedQuerySet
from utilities.utils import deepmerge
from . import serializers
Expand All @@ -34,7 +34,7 @@ def get_view_name(self):
#

class UserViewSet(NetBoxModelViewSet):
queryset = RestrictedQuerySet(model=NetBoxUser).prefetch_related('groups').order_by('username')
queryset = RestrictedQuerySet(model=get_user_model()).prefetch_related('groups').order_by('username')
serializer_class = serializers.UserSerializer
filterset_class = filtersets.UserFilterSet

Expand Down

0 comments on commit 3ab8caa

Please sign in to comment.