Bug 801615 - Edited contacts can't be saved if address book has lists r=Neil a=Callek for CLOSED TREE
authorIan Neal <iann_cvs@blueyonder.co.uk>
Wed, 24 Oct 2012 22:36:38 +0100
changeset 30886 2d80b9fec104c77cc1932bdc74d7f784bb690623
parent 30885 234a03980b2b72f4095fe49de8109d14055a39b3
child 30887 533f194299e9cb33fb2dbd5cc2b07973f90c6f9c
push id1
push userclokep@gmail.com
push dateMon, 07 May 2018 22:45:56 +0000
treeherdercomm-esr60@57eacde5ef40 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersNeil, Callek
bugs801615
Bug 801615 - Edited contacts can't be saved if address book has lists r=Neil a=Callek for CLOSED TREE
suite/mailnews/addrbook/abCardOverlay.js
--- a/suite/mailnews/addrbook/abCardOverlay.js
+++ b/suite/mailnews/addrbook/abCardOverlay.js
@@ -181,22 +181,22 @@ function EditCardOKButton()
   for (let i = 0; i < listDirectoriesCount; i++)
   {
     var subdirectory = directory.addressLists.queryElementAt(i, Components.interfaces.nsIAbDirectory);
     if (subdirectory.isMailList)
     {
       // See if any card in this list is the one we edited.
       // Must compare card contents using .equals() instead of .indexOf()
       // because gEditCard is not really a member of the .addressLists array.
-      let listCardsCount = subdir.addressLists.length;
+      let listCardsCount = subdirectory.addressLists.length;
       for (let index = 0; index < listCardsCount; index++)
       {
         let card = subdirectory.addressLists.queryElementAt(index, Components.interfaces.nsIAbCard);
         if (card.equals(gEditCard.card))
-          foundDirectories.push({directory:subdir, cardIndex:index});
+          foundDirectories.push({directory:subdirectory, cardIndex:index});
       }
     }
   }
  
   CheckAndSetCardValues(gEditCard.card, document, false);
 
   directory.modifyCard(gEditCard.card);