Hide password in the account settings

Fix #811
This commit is contained in:
Olivier Goffart 2013-08-19 13:41:08 +02:00
parent c3b82e6818
commit 29d2094626

View file

@ -448,7 +448,9 @@ void AccountSettings::slotOCInfo( const QString& url, const QString& versionStr,
qDebug() << "#-------# oC found on " << url; qDebug() << "#-------# oC found on " << url;
/* enable the open button */ /* enable the open button */
ui->connectLabel->setOpenExternalLinks(true); ui->connectLabel->setOpenExternalLinks(true);
ui->connectLabel->setText( tr("Connected to <a href=\"%1\">%1</a>.").arg(url) ); QUrl safeUrl(url);
safeUrl.setPassword(QString()); // Remove the password from the URL to avoid showing it in the UI
ui->connectLabel->setText( tr("Connected to <a href=\"%1\">%2</a>.").arg(url, safeUrl.toString()) );
ui->connectLabel->setToolTip( tr("Version: %1 (%2)").arg(versionStr).arg(version)); ui->connectLabel->setToolTip( tr("Version: %1 (%2)").arg(versionStr).arg(version));
ui->_ButtonAdd->setEnabled(true); ui->_ButtonAdd->setEnabled(true);