KeeShare settings fixes

* Moved KeeShare Quiet Success message setting to the KeeShare portion of the application settings
* Removed an assert that caused the application to crash in debugging when a share file could not be found
* Corrected database settings security icon
This commit is contained in:
Jonathan White 2019-06-19 21:24:24 -04:00
parent ef3c2daef1
commit eb9371091a
6 changed files with 18 additions and 20 deletions

View file

@ -148,7 +148,7 @@ void ShareObserver::notifyAbout(const QStringList& success, const QStringList& w
{
QStringList messages;
MessageWidget::MessageType type = MessageWidget::Positive;
if (!(success.isEmpty() || config()->get("GUI/QuietKeeShareSuccess").toBool())) {
if (!(success.isEmpty() || config()->get("KeeShare/QuietSuccess", true).toBool())) {
messages += success;
}
if (!warning.isEmpty()) {
@ -219,8 +219,7 @@ ShareObserver::Result ShareObserver::importShare(const QString& path)
const auto changePath = resolvePath(path, m_db);
auto shareGroup = m_shareToGroup.value(changePath);
if (!shareGroup) {
qWarning("Source for %s does not exist", qPrintable(path));
Q_ASSERT(shareGroup);
qWarning("Group for %s does not exist", qPrintable(path));
return {};
}
const auto reference = KeeShare::referenceOf(shareGroup);