summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLaurie Clark-Michalek <bluepeppers@archlinux.us>2010-09-01 20:07:23 +0100
committerLaurie Clark-Michalek <bluepeppers@archlinux.us>2010-09-01 20:07:23 +0100
commit000f5d5abb4095afa0f82f941dd631d2d7979b88 (patch)
tree7d6d00ee8ee6abe598f1315d5ad9b2b0f5627084
parent60fbe8cc7b7f790d379314d5802bf8028d804350 (diff)
Fixed mpdDisplay with shell method
-rwxr-xr-xarchey38
1 files changed, 4 insertions, 4 deletions
diff --git a/archey3 b/archey3
index 129c88c..54b45b9 100755
--- a/archey3
+++ b/archey3
@@ -346,9 +346,9 @@ class mpdDisplay(display):
try:
return '{statname} in MPD database'.format(statname=self.stat.title()), self.proccess.stats()[self.stat]
except Exception:
- return None
+ return False
else:
- super().render()
+ return super().render()
def format_output(self, instring):
lines = instring.split('\n')
@@ -359,7 +359,7 @@ class mpdDisplay(display):
stats['songs'] = lines[2].split(':')[1].strip()
#if people don't have mpc installed (= no mpd installed) then return None)
except ValueError:
- return None
+ return False
return '{statname} in MPD database'.format(statname=self.stat.title()), stats[self.stat]
@@ -418,7 +418,7 @@ class Archey(object):
if isinstance(out, list):
for o in out:
outputs.append(o)
- elif out is not None:
+ elif out:
outputs.append(out)
else:
continue