Members of the KDE Community are recommended to subscribe to the kde-community mailing list at https://mail.kde.org/mailman/listinfo/kde-community to allow them to participate in important discussions and receive other important announcements

Commit 0864a2dd authored by Daniel Vrátil's avatar Daniel Vrátil 🤖

Session: use StandardDirs to look for akonadiconnectionrc file

parent 73c7dc63
......@@ -34,7 +34,6 @@
#include <QEventLoop>
#include <QTimer>
#include <private/xdgbasedirs_p.h>
#include <private/protocol_exception_p.h>
#include <private/standarddirs_p.h>
......@@ -129,13 +128,11 @@ void Connection::doReconnect()
// try config file next, fall back to defaults if that fails as well
if (serverAddress.isEmpty()) {
const QString connectionConfigFile = SessionPrivate::connectionFile();
const QString connectionConfigFile = StandardDirs::connectionConfigFile();
const QFileInfo fileInfo(connectionConfigFile);
if (!fileInfo.exists()) {
qCDebug(AKONADICORE_LOG) << "Akonadi Client Session: connection config file '"
"akonadi/akonadiconnectionrc' can not be found in"
<< XdgBaseDirs::homePath("config") << "nor in any of"
<< XdgBaseDirs::systemPathList("config");
"akonadi/akonadiconnectionrc' can not be found!";
}
// TODO: share socket setup with server
......
......@@ -72,11 +72,6 @@ void SessionPrivate::reconnect()
connection->reconnect();
}
QString SessionPrivate::connectionFile()
{
return StandardDirs::saveDir("config") + QStringLiteral("/akonadiconnectionrc");
}
void SessionPrivate::socketError(const QString &error)
{
qCWarning(AKONADICORE_LOG) << "Socket error occurred:" << error;
......
......@@ -127,11 +127,6 @@ public:
void clear(bool forceReconnect);
/**
* Default location for akonadiconnectionrc
*/
static QString connectionFile();
Session *mParent = nullptr;
SessionThread *mSessionThread = nullptr;
Connection *connection = nullptr;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment