diff options
| author | Sam Birch <sam.m.birch@gmail.com> | 2014-07-22 12:04:54 -0400 |
|---|---|---|
| committer | Sam Birch <sam.m.birch@gmail.com> | 2014-07-22 12:04:54 -0400 |
| commit | 23d81cc523315aa7159a9dd10f843ba412004614 (patch) | |
| tree | 7ad3ea3c06a062565acdd288186bae78300b962c | |
| parent | 52b379fee609a40b54af4cc70c8b49daf71148a6 (diff) | |
| download | python-pushover-23d81cc523315aa7159a9dd10f843ba412004614.tar.gz | |
Clarified some of the terms
| -rw-r--r-- | pushover.py | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/pushover.py b/pushover.py index 8c5bb6a..73ed59d 100644 --- a/pushover.py +++ b/pushover.py @@ -206,13 +206,13 @@ class Client: return MessageRequest(payload) -def get_client(user=None, config_path='~/.pushover'): +def get_client(profile=None, config_path='~/.pushover'): """Create a :class:`Client` object from a default configuration file. e.g. ``` - #This is the default user (returned by get_client() with no arguments.) - [Pushover] + #This is the default profile (returned by get_client() with no arguments.) + [Default] user_key=xxxxxx # You can specify a device as well. @@ -221,7 +221,7 @@ def get_client(user=None, config_path='~/.pushover'): device=iPhone ``` - * ``user``: the profile to load as a client (`Pushover` by default.) + * ``profile``: the profile to load as a client (`Default` by default.) * ``config_path``: path of the configuration file (`~/.pushover` by default.) """ import ConfigParser @@ -235,7 +235,7 @@ def get_client(user=None, config_path='~/.pushover'): config = ConfigParser.RawConfigParser() config.read(config_path) - section = user if user is not None else 'Pushover' + section = profile if profile is not None else 'Default' return Client( config.get(section, 'user_key'), device=config.get(section, 'device') if config.has_option(section, 'device') else None |
