QVariantMap result = parser.parse (jsonString, &ok).toMap();
if (!ok) {
- emit error(SituareError::INVALID_JSON);
+ emit error(ErrorContext::SITUARE, SituareError::INVALID_JSON);
found = false;
} else {
qDebug() << "Session Key" << result[SESSION_KEY].toString();
qDebug() << callbackUrl;
clearAccountInformation(true);
if(m_freshLogin) {
- emit error(SituareError::LOGIN_FAILED);
+ emit error(ErrorContext::SITUARE, SituareError::LOGIN_FAILED);
} else {
m_freshLogin = true;
- emit error(SituareError::SESSION_EXPIRED);
+ emit error(ErrorContext::SITUARE, SituareError::SESSION_EXPIRED);
}
} else if(callbackUrl.indexOf(LOGIN_PAGE) == 0) {
qDebug() << "correct loginPage";
} else {
qDebug() << "totally wrong webPage";
// we should not get a wrong page at this point
- emit error(SituareError::LOGIN_FAILED);
+ emit error(ErrorContext::SITUARE, SituareError::LOGIN_FAILED);
}
} else {
qDebug() << " Loading of page failed invalid URL" << endl;
// we should not get a wrong page at this point
- emit error(SituareError::LOGIN_FAILED);
+ emit error(ErrorContext::SITUARE, SituareError::LOGIN_FAILED);
}
return found;
}