Related to issue 23761: Remove members after destroying them
authorAugusto Mauch <augusto.mauch@openbravo.com>
Mon, 20 May 2013 17:45:39 +0200
changeset 20405 83655f9606f4
parent 20404 9ddba74744a6
child 20406 28d3d4f719c6
Related to issue 23761: Remove members after destroying them
modules/org.openbravo.userinterface.smartclient/web/org.openbravo.userinterface.smartclient/js/ob-smartclient.js
--- a/modules/org.openbravo.userinterface.smartclient/web/org.openbravo.userinterface.smartclient/js/ob-smartclient.js	Mon May 20 17:06:25 2013 +0200
+++ b/modules/org.openbravo.userinterface.smartclient/web/org.openbravo.userinterface.smartclient/js/ob-smartclient.js	Mon May 20 17:45:39 2013 +0200
@@ -103,7 +103,6 @@
     if (!isc.isA.Array(toDestroy)) {
       toDestroy = [toDestroy];
     }
-    this.removeMembers(toDestroy);
     len = toDestroy.length;
     for (i = 0; i < len; i++) {
       if (toDestroy[nextIndex] && toDestroy[nextIndex].destroy) {
@@ -113,6 +112,7 @@
         nextIndex = nextIndex + 1;
       }
     }
+    this.removeMembers(toDestroy);
   }
 });