Don't query for objects in a response when we know the count is 0.

Review Request #4814 — Created Oct. 21, 2013 and submitted

Information

Djblets
release-0.7.x

Reviewers

Don't query for objects in a response when we know the count is 0.

When building a paginated webapi response, we would always perform a
query for the count and a query for the objects. The latter query is
pointless if the count is 0, so only do it if we know there are objects
to fetch.

Checked queries against an empty resource list. Saw one fewer query.

david
  1. Ship It!

  2. 
      
chipx86
Review request changed

Status: Closed (submitted)

Loading...