@@ -181,7 +181,7 @@ class Client:
181
181
182
182
def __init__ (self , user_key = None , device = None , api_token = None ,
183
183
config_path = "~/.pushoverrc" , profile = "Default" ):
184
- params = _get_config (profile , config_path , user_key , api_token )
184
+ params = _get_config (profile , config_path , user_key , api_token , device )
185
185
self .user_key = params ["user_key" ]
186
186
if not self .user_key :
187
187
raise UserError
@@ -244,7 +244,7 @@ def send_message(self, message, **kwords):
244
244
245
245
246
246
def _get_config (profile = 'Default' , config_path = '~/.pushoverrc' ,
247
- user_key = None , api_token = None ):
247
+ user_key = None , api_token = None , device = None ):
248
248
config_path = os .path .expanduser (config_path )
249
249
config = RawConfigParser ()
250
250
config .read (config_path )
@@ -257,6 +257,8 @@ def _get_config(profile='Default', config_path='~/.pushoverrc',
257
257
params ["user_key" ] = user_key
258
258
if api_token :
259
259
params ["api_token" ] = api_token
260
+ if device :
261
+ params ["device" ] = device
260
262
261
263
if not TOKEN :
262
264
init (params ["api_token" ])
0 commit comments