Skip to content

Commit

Permalink
Merge pull request #123 from gtmanfred/develop
Browse files Browse the repository at this point in the history
fix locals context
  • Loading branch information
gtmanfred authored Mar 2, 2018
2 parents bdbd79a + 72b0c55 commit 877ae68
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions pepper/libpepper.py
Original file line number Diff line number Diff line change
Expand Up @@ -447,13 +447,14 @@ def login(self, username=None, password=None, eauth=None, **kwargs):
authentication token or an empty dict
'''
local = locals()
kwargs.update(
dict(
(key, locals()[key]) for key in (
(key, local[key]) for key in (
'username',
'password',
'eauth'
) if locals().get(key, None) is not None
) if local.get(key, None) is not None
)
)
self.auth = self._send_auth('/login', **kwargs).get('return', [{}])[0]
Expand Down

0 comments on commit 877ae68

Please sign in to comment.