diff options
-rw-r--r-- | service/pixelated/account_recovery.py | 4 | ||||
-rw-r--r-- | service/pixelated/resources/backup_account_resource.py | 2 | ||||
-rw-r--r-- | service/test/unit/test_account_recovery.py | 4 |
3 files changed, 5 insertions, 5 deletions
diff --git a/service/pixelated/account_recovery.py b/service/pixelated/account_recovery.py index 39614b4c..cca88760 100644 --- a/service/pixelated/account_recovery.py +++ b/service/pixelated/account_recovery.py @@ -24,9 +24,9 @@ class AccountRecovery(object): self._session = session @inlineCallbacks - def update_recovery_code(self, recovery_code): + def update_recovery_code(self): try: - response = yield self._session.update_recovery_code(recovery_code) + response = yield self._session.update_recovery_code('123') returnValue(response) except Exception as e: log.warn('Something went wrong when trying to save the recovery code') diff --git a/service/pixelated/resources/backup_account_resource.py b/service/pixelated/resources/backup_account_resource.py index 0b73bc35..7c66336f 100644 --- a/service/pixelated/resources/backup_account_resource.py +++ b/service/pixelated/resources/backup_account_resource.py @@ -59,6 +59,6 @@ class BackupAccountResource(BaseResource): request.setResponseCode(INTERNAL_SERVER_ERROR) request.finish() - d = account_recovery.update_recovery_code("123") + d = account_recovery.update_recovery_code() d.addCallbacks(update_response, error_response) return NOT_DONE_YET diff --git a/service/test/unit/test_account_recovery.py b/service/test/unit/test_account_recovery.py index 51ba3fd0..026d161f 100644 --- a/service/test/unit/test_account_recovery.py +++ b/service/test/unit/test_account_recovery.py @@ -29,5 +29,5 @@ class AccountRecoveryTest(unittest.TestCase): mock_session = Mock() account_recovery = AccountRecovery(mock_session) - yield account_recovery.update_recovery_code('ABC') - mock_session.update_recovery_code.assert_called_once_with('ABC') + yield account_recovery.update_recovery_code() + mock_session.update_recovery_code.assert_called_once_with('123') |