fix(form): Check for action type instead of key

This commit is contained in:
Suraj Shetty 2021-01-25 22:04:52 +05:30
parent 4f32726cd7
commit 60470a9ae6

View file

@ -1675,7 +1675,7 @@ frappe.ui.form.Form = class FrappeForm {
}
// no need to update timeline of owner of comment
// gets handled via comment submit code
if (!(['add', 'update'].includes(key) && doc.doctype === 'Comment' && doc.owner === frappe.session.user)) {
if (!(['add', 'update'].includes(action) && doc.doctype === 'Comment' && doc.owner === frappe.session.user)) {
this.timeline && this.timeline.refresh();
}
});