[modules/prime] Minor fix for return type

Also, add module to doc
This commit is contained in:
Tobias Witek 2019-02-14 20:09:41 +01:00
parent 092da0b41e
commit 2522b428b6
2 changed files with 3 additions and 3 deletions

View file

@ -5,7 +5,7 @@
[![Test Coverage](https://codeclimate.com/github/tobi-wan-kenobi/bumblebee-status/badges/coverage.svg)](https://codeclimate.com/github/tobi-wan-kenobi/bumblebee-status/coverage) [![Test Coverage](https://codeclimate.com/github/tobi-wan-kenobi/bumblebee-status/badges/coverage.svg)](https://codeclimate.com/github/tobi-wan-kenobi/bumblebee-status/coverage)
[![Issue Count](https://codeclimate.com/github/tobi-wan-kenobi/bumblebee-status/badges/issue_count.svg)](https://codeclimate.com/github/tobi-wan-kenobi/bumblebee-status) [![Issue Count](https://codeclimate.com/github/tobi-wan-kenobi/bumblebee-status/badges/issue_count.svg)](https://codeclimate.com/github/tobi-wan-kenobi/bumblebee-status)
**Many, many thanks to all contributors! As of now, 35 of the modules are from various contributors (!), and only 18 from myself.** **Many, many thanks to all contributors! As of now, 36 of the modules are from various contributors (!), and only 18 from myself.**
![Solarized Powerline](https://github.com/tobi-wan-kenobi/bumblebee-status/blob/master/screenshots/themes/powerline-solarized.png) ![Solarized Powerline](https://github.com/tobi-wan-kenobi/bumblebee-status/blob/master/screenshots/themes/powerline-solarized.png)

View file

@ -56,7 +56,7 @@ class Module(bumblebee.engine.Module):
try: try:
res = bumblebee.util.execute("prime-select query") res = bumblebee.util.execute("prime-select query")
except RuntimeError: except RuntimeError:
return ["n/a"] return "n/a"
for line in res.split("\n"): for line in res.split("\n"):
if not line: continue if not line: continue
@ -64,6 +64,6 @@ class Module(bumblebee.engine.Module):
return self.nvidiastring return self.nvidiastring
if "intel" in line: if "intel" in line:
return self.intelstring return self.intelstring
return ["n/a"] return "n/a"
# vim: tabstop=8 expandtab shiftwidth=4 softtabstop=4 # vim: tabstop=8 expandtab shiftwidth=4 softtabstop=4