#include "networkjobs.h"
#include "account.h"
#include "selectivesyncdialog.h"
+#include "creds/abstractcredentials.h"
#include <QDebug>
#include <QDesktopServices>
void FolderWizardRemotePath::slotHandleNetworkError(QNetworkReply *reply)
{
qDebug() << "** webdav mkdir request failed:" << reply->error();
- showWarn(tr("Failed to create the folder on %1. Please check manually.")
- .arg(Theme::instance()->appNameGUI()));
+ if( reply && !_account->credentials()->stillValid(reply) ) {
+ showWarn(tr("Authentication failed accessing %1").arg(Theme::instance()->appNameGUI()));
+ } else {
+ showWarn(tr("Failed to create the folder on %1. Please check manually.")
+ .arg(Theme::instance()->appNameGUI()));
+ }
}
static QTreeWidgetItem* findFirstChild(QTreeWidgetItem *parent, const QString& text)
// status.php could not be loaded (network or server issue!).
void ConnectionValidator::slotNoStatusFound(QNetworkReply *reply)
{
- _errors.append(tr("Unable to connect to %1").arg(_account->url().toString()));
- _errors.append( reply->errorString() );
+ if( reply && ! _account->credentials()->stillValid(reply)) {
+ _errors.append(tr("Authentication error: Either username or password are wrong."));
+ } else {
+ _errors.append(tr("Unable to connect to %1").arg(_account->url().toString()));
+ _errors.append( reply->errorString() );
+ }
reportResult( StatusNotFound );
}