diff --git a/src/core/Entry.cpp b/src/core/Entry.cpp index 162685492..b35c201d9 100644 --- a/src/core/Entry.cpp +++ b/src/core/Entry.cpp @@ -258,6 +258,9 @@ void Entry::setAttribute(const QString& key, const QString& value, bool protect) if (protect) { m_protectedAttributes.insert(key); } + else { + m_protectedAttributes.remove(key); + } if (isDefaultAttributue(key)) { Q_EMIT dataChanged(this); @@ -278,6 +281,9 @@ void Entry::setAttachment(const QString& key, const QByteArray& value, bool prot if (protect) { m_protectedAttachments.insert(key); } + else { + m_protectedAttachments.remove(key); + } } void Entry::removeAttachment(const QString& key)