mirror of
https://github.com/ansible/awx.git
synced 2026-03-22 03:17:39 -02:30
Missing call to all when querying the relation manager
This commit is contained in:
@@ -797,7 +797,7 @@ class GroupChildrenRemove(DestroyAPIView):
|
|||||||
def destroy(self, request, *args, **kwargs):
|
def destroy(self, request, *args, **kwargs):
|
||||||
parent_group = self.get_object()
|
parent_group = self.get_object()
|
||||||
group = Group.objects.get(id=kwargs['subgroup_pk'])
|
group = Group.objects.get(id=kwargs['subgroup_pk'])
|
||||||
if group not in parent_group.children:
|
if group not in parent_group.children.all():
|
||||||
return Response(status=status.HTTP_404_NOT_FOUND)
|
return Response(status=status.HTTP_404_NOT_FOUND)
|
||||||
group.mark_inactive_recursive(parent_group)
|
group.mark_inactive_recursive(parent_group)
|
||||||
return Response()
|
return Response()
|
||||||
|
|||||||
Reference in New Issue
Block a user