diff options
-rw-r--r-- | plugins/SongStatus.py | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/plugins/SongStatus.py b/plugins/SongStatus.py index c927e1a..45a8dc8 100644 --- a/plugins/SongStatus.py +++ b/plugins/SongStatus.py @@ -45,7 +45,10 @@ class wgSongStatus(QtGui.QWidget): self.lblInfo.setText(self.format(format.params(song, values))) def updateFormat(self): - self.format=format.compile(settings.get('songstatus.format', SS_DEFAULT_FORMAT)) + try: + self.format=format.compile(settings.get('songstatus.format', SS_DEFAULT_FORMAT)) + except Exception, e: + self.format=lambda p: "Invalid format: %s"%(e) def text(self): return self.lblInfo.text() |