From 58919b078db6c163f47bcf03dcc576bb5c3ac56f Mon Sep 17 00:00:00 2001 From: Abyss777 Date: Fri, 21 Jul 2017 18:42:41 +0500 Subject: Fix adding new device if Geofences column visible --- web/app/view/edit/Devices.js | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) (limited to 'web/app/view') diff --git a/web/app/view/edit/Devices.js b/web/app/view/edit/Devices.js index d601800..d5e6d5f 100644 --- a/web/app/view/edit/Devices.js +++ b/web/app/view/edit/Devices.js @@ -161,9 +161,11 @@ Ext.define('Traccar.view.edit.Devices', { }, renderer: function (value) { var i, result = ''; - for (i = 0; i < value.length; i++) { - result += Traccar.AttributeFormatter.geofenceIdFormatter(value[i]); - result += (i < value.length - 1) ? ', ' : ''; + if (Ext.isArray(value)) { + for (i = 0; i < value.length; i++) { + result += Traccar.AttributeFormatter.geofenceIdFormatter(value[i]); + result += (i < value.length - 1) ? ', ' : ''; + } } return result; } -- cgit v1.2.3