refresh only if timeline (#5050)

This commit is contained in:
Shreya Shah 2018-02-22 11:01:54 +05:30 committed by Rushabh Mehta
parent a1b46cdfac
commit c8d13c07ba

View file

@ -140,7 +140,7 @@ frappe.ui.form.Attachments = Class.extend({
}
me.remove_fileid(fileid);
me.frm.get_docinfo().communications.push(r.message);
me.frm.timeline.refresh();
me.frm.timeline && me.frm.timeline.refresh();
if (callback) callback();
}
});