KeyError: 'cpucore' when exporting data to InfluxDB (issue #729)

pull/755/head
nicolargo 2015-12-05 15:13:24 +01:00
parent b57de62392
commit f3c7db8fd4
1 changed files with 1 additions and 1 deletions

View File

@ -139,7 +139,7 @@ class Plugin(GlancesPlugin):
msg = '{0:8}'.format('LOAD')
ret.append(self.curse_add_line(msg, "TITLE"))
# Core number
if self.stats['cpucore'] > 0:
if 'cpucore' in self.stats and self.stats['cpucore'] > 0:
msg = '{0}-core'.format(int(self.stats['cpucore']))
ret.append(self.curse_add_line(msg))
# New line