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 ee9428a0 authored by Laurent Montel's avatar Laurent Montel 😁

Don't assign invalid collection.

When kmail start CommonKernel can not be initialized
=> CommonKernel->sentCollectionFolder(); is invalid.
=> we can see correct collection in combobox but
void ComposerViewBase::slotFccCollectionCheckResult(KJob *job) return an error
=> change to default collection name.

But found by David

(cherry picked from commit 574f5864)
parent 4697fd79
......@@ -619,6 +619,7 @@ void KMComposerWin::readConfig(bool reload /* = false */)
if (!ident.fcc().isEmpty()) {
fccName = ident.fcc();
}
qDebug() <<" fccName" << fccName;
setFcc(fccName);
}
......@@ -1618,6 +1619,7 @@ void KMComposerWin::setMessage(const KMime::Message::Ptr &newMsg, bool lastSignS
if (auto hdr = mMsg->headerByType("X-KMail-Fcc")) {
kmailFcc = hdr->asUnicodeString();
}
qDebug() << "sssssssssssssssssssssssssss22222222" << kmailFcc;
if (kmailFcc.isEmpty()) {
setFcc(ident.fcc());
} else {
......@@ -1703,9 +1705,10 @@ void KMComposerWin::setFcc(const QString &idString)
} else {
col = Akonadi::Collection(idString.toLongLong());
}
mComposerBase->setFcc(col);
mFccFolder->setCollection(col);
if (col.isValid()) {
mComposerBase->setFcc(col);
mFccFolder->setCollection(col);
}
}
bool KMComposerWin::isComposerModified() const
......
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