fixed minor errors
This commit is contained in:
parent
25755a934c
commit
47c1697f3d
|
@ -177,7 +177,10 @@ class Api(object):
|
|||
return None
|
||||
|
||||
def get_venue(self, venue):
|
||||
return self.search_venue(venue)[0]
|
||||
try:
|
||||
return self.search_venue(venue)[0]
|
||||
except IndexError:
|
||||
return None
|
||||
|
||||
def search_venue(self, venue):
|
||||
return Venue.search(self, search_item = venue)
|
||||
|
|
|
@ -311,7 +311,8 @@ class Artist(LastfmBase, Cacheable, Sharable, Shoutable, Searchable, Taggable):
|
|||
]
|
||||
self._bio = Wiki(
|
||||
self,
|
||||
published = datetime(*(time.strptime(
|
||||
published = data.findtext('bio/published').strip() and
|
||||
datetime(*(time.strptime(
|
||||
data.findtext('bio/published').strip(),
|
||||
'%a, %d %b %Y %H:%M:%S +0000'
|
||||
)[0:6])),
|
||||
|
|
Loading…
Reference in New Issue