fix removeAttribute to take into account attribute name, closes #804

pull/255/head
zadam 2020-01-03 08:55:13 +07:00
parent ac75fd2ca3
commit d0c655f66a
1 changed files with 1 additions and 1 deletions

@ -525,7 +525,7 @@ class Note extends Entity {
const attributes = await this.loadOwnedAttributesToCache();
for (const attribute of attributes) {
if (attribute.type === type && (value === undefined || value === attribute.value)) {
if (attribute.type === type && attribute.name === name && (value === undefined || value === attribute.value)) {
attribute.isDeleted = true;
await attribute.save();