Fixed query bug.

This commit is contained in:
2018-02-27 22:37:48 -05:00
parent d585bdf49d
commit ae0789cfb7
2 changed files with 3 additions and 3 deletions

View File

@ -124,7 +124,7 @@ Get a list of potential autocompletion phrases.
| Param |Required [y/n]| Input type | Function | | Param |Required [y/n]| Input type | Function |
|:---:|:---:|:---:|:---:| |:---:|:---:|:---:|:---:|
|query|Yes|String| The query of the autocompletion.| |q|Yes|String| The query of the autocompletion.|
**Attributes:** **Attributes:**

View File

@ -7,7 +7,7 @@ class Autocomplete(CardsObject):
Get a list of potential autocompletion phrases. Get a list of potential autocompletion phrases.
Positional arguments: Positional arguments:
query : str ........... The query of the autocompletion. q : str ........... The query of the autocompletion.
Optional arguments: Optional arguments:
Inherits arguments from CardsObject. Inherits arguments from CardsObject.
@ -22,7 +22,7 @@ class Autocomplete(CardsObject):
>>> auto.total_items() >>> auto.total_items()
""" """
def __init__(self, **kwargs): def __init__(self, **kwargs):
if kwargs.get('query') is None: if kwargs.get('q') is None:
raise TypeError('No query provided to search by') raise TypeError('No query provided to search by')
self.dict = { self.dict = {