From 0069a4200b1d087c9d931289cd57746aaa4e23bd Mon Sep 17 00:00:00 2001 From: Francis Lachapelle Date: Fri, 19 Jul 2013 10:43:21 -0400 Subject: [PATCH] Handle possible jQuery error with DnD of contacts --- UI/WebServerResources/ContactsUI.js | 22 +++++++++++----------- 1 file changed, 11 insertions(+), 11 deletions(-) diff --git a/UI/WebServerResources/ContactsUI.js b/UI/WebServerResources/ContactsUI.js index b83f8a00d..b2ef19b4c 100644 --- a/UI/WebServerResources/ContactsUI.js +++ b/UI/WebServerResources/ContactsUI.js @@ -1502,18 +1502,18 @@ function unsetCategoryOnNode(contactNode, category) { function configureDraggables() { if ($("contactFolders")) { var rows = jQuery("tr.vcard"); - rows.draggable("destroy"); + try { rows.draggable("destroy"); } catch (e) {} rows.draggable({ - helper: function (event) { return '
'; }, - start: startDragging, - drag: whileDragging, - stop: stopDragging, - appendTo: 'body', - cursorAt: { right: 25 }, - scroll: false, - distance: 4, - zIndex: 20 - }); + helper: function (event) { return '
'; }, + start: startDragging, + drag: whileDragging, + stop: stopDragging, + appendTo: 'body', + cursorAt: { right: 25 }, + scroll: false, + distance: 4, + zIndex: 20 + }); } }