]> kaliko git repositories - mpd-goodies.git/commitdiff
* nalbum: Check availability of next album before starting fading out
authorkaliko <kaliko@azylum.org>
Thu, 14 Jun 2012 13:43:12 +0000 (13:43 +0000)
committerkaliko <kaliko@azylum.org>
Thu, 14 Jun 2012 13:43:12 +0000 (13:43 +0000)
src/nalbum

index ae53c79947cc3f937fc84dd95fe44439cda5b405..dbb2e14eae09da12e1ee0da1f80366815207a7ac 100755 (executable)
@@ -101,11 +101,12 @@ class Nalbum(Goodie):
         """"""
         print 'Connecting %s:%i' % (self.cli_options.host, self.cli_options.port)
         self.mpdConnect()
+        nalbum = self._get_next()
         self.init_vol = int(self.client.status().get('volume'))
         if self.cli_options.time:
             print 'Cross fading next album'
             self._fade()
-        self.client.play(self._get_next())
+        self.client.play(nalbum)
         if self.cli_options.time:
             self._fade(io='in')
         self.client.disconnect()