rem: if (identities.Count() > 0 ) { identity = identities.GetElementAt(0).QueryInterface(Components.interfaces.nsIMsgIdentity); 
add: if (identities.Count() > 0 ) { identity = getBestIdentity(identities, optionalHint); 
context: function getIdentityForServer(server){    var identity = null;    if(server) {		// get the identity associated with this server        var identities = accountManager.GetIdentitiesForServer(server);        // dump("identities = " + identities + "\n");        // just get the first one        if (identities.Count() > 0 ) {            identity = identities.GetElementAt(0).QueryInterface(Components.interfaces.nsIMsgIdentity);          }    }    return identity;}
meta: 9421	/local1/tlutelli/issta_data/temp/all_js/javascript/2006_temp/2006/9421/a0177d80a7fa24c901d98f8c18e25092a45defcc/mailCommands.js/clean/mailnews/base/resources/content/mailCommands.js