Improve stability of DDG searching
This commit is contained in:
parent
bba0840a17
commit
bb4fe1a8fe
1 changed files with 4 additions and 1 deletions
|
@ -18,7 +18,10 @@ class DDGSearch:
|
|||
|
||||
@property
|
||||
def type(self):
|
||||
return self.ddgres.getFirstNode("Type").getContent()
|
||||
if self.ddgres.hasNode("Type"):
|
||||
return self.ddgres.getFirstNode("Type").getContent()
|
||||
else:
|
||||
return ""
|
||||
|
||||
@property
|
||||
def definition(self):
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue