Add ability to rename attachments

* Closes #4758
This commit is contained in:
fpohtmeh authored and Jonathan White committed 2020-08-31 23:06:10 -04:00
1 parent e53850627f
commit bbdfbe64da
7 files changed
+64

No files matched your search

+7
View File
@@ -112,6 +112,13 @@ void EntryAttachments::remove(const QStringList& keys)
}
}
void EntryAttachments::rename(const QString& key, const QString& newKey)
{
const QByteArray val = value(key);
remove(key);
set(newKey, val);
}
bool EntryAttachments::isEmpty() const
{
return m_attachments.isEmpty();