Skip to content

Commit

Permalink
Merge pull request #15727 from lfu/service_query_optimize
Browse files Browse the repository at this point in the history
Optimize the query of a service's orchestration_stacks.
  • Loading branch information
gmcculloug committed Aug 3, 2017
2 parents d9cd967 + 0133198 commit 0f44f9c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion app/models/service.rb
Original file line number Diff line number Diff line change
Expand Up @@ -201,7 +201,7 @@ def atomic?
end

def orchestration_stacks
service_resources.where(:resource_type => 'OrchestrationStack').collect(&:resource)
service_resources.where(:resource_type => 'OrchestrationStack').includes(:resource).collect(&:resource)
end

def generic_objects
Expand Down

0 comments on commit 0f44f9c

Please sign in to comment.