Skip to content

Commit

Permalink
Removed default values for start and rows from the search method. Tha…
Browse files Browse the repository at this point in the history
…nks, jarek.zgoda.

This will allow people to let solr determine what the default for those should be.


git-svn-id: https://pysolr.googlecode.com/svn/trunk@11 13ae9d4a-4d43-0410-997b-81b7443f7ec1
  • Loading branch information
jkocherhans committed Mar 14, 2008
1 parent 21b36e1 commit 811be66
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions pysolr.py
Original file line number Diff line number Diff line change
Expand Up @@ -229,9 +229,13 @@ def double_to_python(self, value):

# API Methods ############################################################

def search(self, q, sort=None, start=0, rows=20):
def search(self, q, sort=None, start=None, rows=None):
"""Performs a search and returns the results."""
params = {'q': q, 'start': start, 'rows': rows}
params = {'q': q}
if start:
params['start'] = start
if rows:
params['rows'] = rows
if sort:
params['sort'] = sort
response = self._select(params)
Expand Down

0 comments on commit 811be66

Please sign in to comment.