Skip to content
Snippets Groups Projects
Commit 442e39c3 authored by Dan Michael O. Heggø's avatar Dan Michael O. Heggø
Browse files

Merge pull request #29 from kyv/ask

use #ask from smw api
parents c80c1ca8 0a16afc6
No related branches found
No related tags found
No related merge requests found
...@@ -623,3 +623,9 @@ class Site(object): ...@@ -623,3 +623,9 @@ class Site(object):
return result['expandtemplates']['*'], result['parsetree']['*'] return result['expandtemplates']['*'], result['parsetree']['*']
else: else:
return result['expandtemplates']['*'] return result['expandtemplates']['*']
def ask(self, query, title = None):
kwargs = {}
if title is None: kwargs['title'] = title
result = self.raw_api('ask', query = query, **kwargs)
return result['query']['results']
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment