PEP fixes

This commit is contained in:
Oliver committed 2021-07-21 21:24:18 +10:00
1 parent 85a40ec418
commit 9cf372f633
2 files changed
+1 -2

No files matched your search

+1 -1
View File
@@ -351,7 +351,7 @@ class StockLocationList(generics.ListCreateAPIView):
loc = StockLocation.objects.get(pk=exclude_tree)
queryset = queryset.exclude(
pk__in=[l.pk for l in loc.get_descendants(include_self=True)]
pk__in=[subloc.pk for subloc in loc.get_descendants(include_self=True)]
)
except (ValueError, StockLocation.DoesNotExist):