mirror of
https://github.com/andreili/klipper.git
synced 2025-08-23 19:34:06 +02:00
statistics: Avoid adding extra blank spaces on empty stats reports
Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
This commit is contained in:
parent
1d569a6631
commit
6d59279438
@ -65,8 +65,8 @@ class PrinterStats:
|
||||
def generate_stats(self, eventtime):
|
||||
stats = [cb(eventtime) for cb in self.stats_cb]
|
||||
if max([s[0] for s in stats]):
|
||||
logging.info("Stats %.1f: %s", eventtime,
|
||||
' '.join([s[1] for s in stats]))
|
||||
stats_str = ' '.join([s[1] for s in stats if s[1]])
|
||||
logging.info("Stats %.1f: %s", eventtime, stats_str)
|
||||
return eventtime + 1.
|
||||
|
||||
def load_config(config):
|
||||
|
Loading…
x
Reference in New Issue
Block a user