Current location

narf Source control manager Git

summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorshtrom <shtrom@1991c358-8f32-0410-a49a-990740bdf4c2>2007-11-18 20:18:25 +0000
committershtrom <shtrom@1991c358-8f32-0410-a49a-990740bdf4c2>2007-11-18 20:18:25 +0000
commita01e82ad5013941609f09d9622ca7647feff7540 (patch)
tree22a23e492d93aea9d5252334bdd9ab7d09c11d89 /lastfm.py
parentad709bd4682941db4bf1f0ee680352683ca7635a (diff)
Update the information after complete innitialisation of the object...
git-svn-id: svn+ssh://scm.narf.ssji.net/svn/shtrom/scripts@64 1991c358-8f32-0410-a49a-990740bdf4c2
Diffstat (limited to 'lastfm.py')
-rwxr-xr-xlastfm.py6
1 files changed, 3 insertions, 3 deletions
diff --git a/lastfm.py b/lastfm.py
index 24a3af2..f5874e3 100755
--- a/lastfm.py
+++ b/lastfm.py
@@ -51,6 +51,7 @@ class LastFM:
self.setUsername(username)
self._proxies = proxies
self.scrobbling = False
+ self.updateData()
def __str__(self):
return "Last.fm song tracker for user %s.%s" % (self._username,
@@ -58,12 +59,11 @@ class LastFM:
" Last song was \"%(n)s\" by \"%(a)s\" in album \"%(b)s\"."))
def getUsername(self):
- return self.username
+ return self._username
def setUsername(self, username):
self._username = username
self.lastSongs = []
- self.updateData()
def updateData(self):
"""
@@ -76,7 +76,7 @@ class LastFM:
xmldocument = urlopen(self.LASTFM_FORMAT_URL % self._username,
self._proxies)
xmltree = minidom.parse(xmldocument)
- except:
+ except
print "Error parsing XML from Last.fm..."
return False