rem: cardForEmailAddress.editCardToDatabase(""); 
add: addrbook.modifyCard(cardForEmailAddress); 
context: function allowRemoteContentForSender(){  // get the sender of the msg hdr  var msgHdr = msgHdrForCurrentMessage();  if (!msgHdr)    return;    var headerParser = Components.classes["@mozilla.org/messenger/headerparser;1"]                      .getService(Components.interfaces.nsIMsgHeaderParser);  var names = {};  var addresses = {};  var fullNames = {};  var numAddresses;    numAddresses = headerParser.parseHeadersWithArray(msgHdr.author, addresses, names, fullNames);  var authorEmailAddress = addresses.value[0];  if (!authorEmailAddress)    return;    // search through all of our local address books looking for a match.  var parentDir = RDF.GetResource("moz-abdirectory://").QueryInterface(Components.interfaces.nsIAbDirectory);  var enumerator = parentDir.childNodes;  var cardForEmailAddress;  var addrbook;  while (!cardForEmailAddress && enumerator.hasMoreElements())  {    addrbook = enumerator.getNext();    if (addrbook instanceof Components.interfaces.nsIAbMDBDirectory)      cardForEmailAddress = addrbook.cardForEmailAddress(authorEmailAddress);  }  var allowRemoteContent = false;  if (cardForEmailAddress)  {    // set the property for remote content    cardForEmailAddress.allowRemoteContent = true;    cardForEmailAddress.editCardToDatabase("");     allowRemoteContent = true;  }  else  {    var args = {primaryEmail:authorEmailAddress, displayName:names.value[0],                allowRemoteContent:true};    // create a new card and set the property    window.openDialog("chrome://messenger/content/addressbook/abNewCardDialog.xul",                      "", "chrome,resizable=no,titlebar,modal,centerscreen", args);    allowRemoteContent = args.allowRemoteContent;  }     // reload the message if we've updated the remote content policy for the sender    if (allowRemoteContent)    MsgReload();}
meta: 8395	/local1/tlutelli/issta_data/temp/all_js/javascript/2006_temp/2006/8395/55c3839e6e4cd19eac52efb7a944cd051cc54892/mailWindowOverlay.js/clean/mail/base/content/mailWindowOverlay.js