From c179cec8a018fa5cac3de02780a195e99cd58ed8 Mon Sep 17 00:00:00 2001 From: yuri Date: Tue, 15 May 2018 11:50:59 +0300 Subject: [PATCH] fix attachment multiple --- client/src/views/fields/attachment-multiple.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/client/src/views/fields/attachment-multiple.js b/client/src/views/fields/attachment-multiple.js index 8bac40cbab..21b9ac21d3 100644 --- a/client/src/views/fields/attachment-multiple.js +++ b/client/src/views/fields/attachment-multiple.js @@ -253,7 +253,7 @@ Espo.define('views/fields/attachment-multiple', 'views/fields/base', function (D }, pushAttachment: function (attachment, link) { - var arr = _.clone(this.model.get(this.idsName)); + var arr = _.clone(this.model.get(this.idsName) || []); arr.push(attachment.id); this.model.set(this.idsName, arr);