Skip to content

Commit

Permalink
Merge branch 'develop' of github.com:nicolargo/glances into develop
Browse files Browse the repository at this point in the history
  • Loading branch information
nicolargo committed Dec 17, 2019
2 parents 48cb5ef + d7a3972 commit 57ffb71
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions glances/plugins/glances_processlist.py
Original file line number Diff line number Diff line change
Expand Up @@ -117,9 +117,10 @@ def __init__(self, args=None, config=None):
self.pid_max = glances_processes.pid_max

# Set the default sort key if it is defined in the configuration file
if 'processlist' in config.as_dict() and 'sort_key' in config.as_dict()['processlist']:
logger.debug('Configuration overwrites processes sort key by {}'.format(config.as_dict()['processlist']['sort_key']))
glances_processes.set_sort_key(config.as_dict()['processlist']['sort_key'], False)
if config is not None:
if 'processlist' in config.as_dict() and 'sort_key' in config.as_dict()['processlist']:
logger.debug('Configuration overwrites processes sort key by {}'.format(config.as_dict()['processlist']['sort_key']))
glances_processes.set_sort_key(config.as_dict()['processlist']['sort_key'], False)

# Note: 'glances_processes' is already init in the processes.py script

Expand Down

0 comments on commit 57ffb71

Please sign in to comment.