diff options
author | Kitsune Ral <Kitsune-Ral@users.sf.net> | 2016-05-27 16:49:15 +0900 |
---|---|---|
committer | Kitsune Ral <Kitsune-Ral@users.sf.net> | 2016-05-27 16:49:15 +0900 |
commit | a2c08f646bf2d6fe0ce385940b5c1bb7b430d5fb (patch) | |
tree | 28a6876b08ce27757ffe3bddb053916768ce6426 /jobs | |
parent | d5df4568d34487aea519ae97dd1666927dcfb62b (diff) | |
download | libquotient-a2c08f646bf2d6fe0ce385940b5c1bb7b430d5fb.tar.gz libquotient-a2c08f646bf2d6fe0ce385940b5c1bb7b430d5fb.zip |
Don't assign the token twice
In a case when authentication doesn't even happen, PasswordLogin job
won't run. The better place to assign (and log) the token is in
Connection::connectWithToken(), therefore.
Diffstat (limited to 'jobs')
-rw-r--r-- | jobs/passwordlogin.cpp | 2 |
1 files changed, 0 insertions, 2 deletions
diff --git a/jobs/passwordlogin.cpp b/jobs/passwordlogin.cpp index d989815f..6cf45b26 100644 --- a/jobs/passwordlogin.cpp +++ b/jobs/passwordlogin.cpp @@ -88,9 +88,7 @@ void PasswordLogin::parseJson(const QJsonDocument& data) fail( BaseJob::UserDefinedError, "Unexpected data" ); } d->returned_token = json.value("access_token").toString(); - qDebug() << d->returned_token; d->returned_server = json.value("home_server").toString(); d->returned_id = json.value("user_id").toString(); - connection()->setToken(d->returned_token); emitResult(); } |