Skip to content

Commit

Permalink
Fetch all objects to include in one query to improve performance mass…
Browse files Browse the repository at this point in the history
…ively
  • Loading branch information
Cotix committed Jan 19, 2019
1 parent 8e32477 commit f75006c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion flask_restless/views/base.py
Original file line number Diff line number Diff line change
Expand Up @@ -1413,7 +1413,7 @@ def get_all_inclusions(self, instance_or_instances):
# one instance. Otherwise, collect the resources to include for
# each instance in `instances`.
if isinstance(instance_or_instances, Query):
instances = instance_or_instances
instances = instance_or_instances.all()
to_include = set(chain(map(self.resources_to_include, instances)))
else:
instance = instance_or_instances
Expand Down

0 comments on commit f75006c

Please sign in to comment.