Skip to content

Commit

Permalink
Skip traits
Browse files Browse the repository at this point in the history
  • Loading branch information
khvn26 committed May 14, 2024
1 parent c435a70 commit 2899fd1
Show file tree
Hide file tree
Showing 3 changed files with 2 additions and 3 deletions.
1 change: 0 additions & 1 deletion api/environments/models.py
Original file line number Diff line number Diff line change
Expand Up @@ -386,7 +386,6 @@ def _get_environment_document_from_db(
"identity",
"identity__environment",
).prefetch_related(
"identity__identity_traits",
Prefetch(
"identity__identity_features",
queryset=FeatureState.objects.select_related(
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -108,7 +108,7 @@ def test_get_environment_document(
url = reverse("api-v1:environment-document")

# When
with django_assert_num_queries(16):
with django_assert_num_queries(15):
response = client.get(url)

# Then
Expand Down
2 changes: 1 addition & 1 deletion api/util/mappers/sdk.py
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ def map_environment_to_sdk_document(environment: "Environment") -> SDKDocument:

# Prepare relationships.
engine_environment.identity_overrides = [
map_identity_to_engine(identity)
map_identity_to_engine(identity, with_traits=False)
for identity in identities_with_overrides.values()
]

Expand Down

0 comments on commit 2899fd1

Please sign in to comment.