Bug 785147 - Contacts API: fix import contacts from SIM card. r=fabrice
authorGregor Wagner <anygregor@gmail.com>
Thu, 23 Aug 2012 11:48:33 -0700
changeset 105237 f4c286fc04f0a4275cdb24546a916f3750f58a8d
parent 105236 c1e3da499d876c011d23fa20c272a9101454b5d4
child 105238 05d1a3fba90bd35e41719d48a28641952c9fb454
child 105240 b173c738d021d6fd655c31a0e68305858cdf841b
push id55
push usershu@rfrn.org
push dateThu, 30 Aug 2012 01:33:09 +0000
reviewersfabrice
bugs785147
milestone17.0a1
Bug 785147 - Contacts API: fix import contacts from SIM card. r=fabrice
dom/contacts/ContactManager.js
--- a/dom/contacts/ContactManager.js
+++ b/dom/contacts/ContactManager.js
@@ -543,17 +543,17 @@ ContactManager.prototype = {
     let request;
     request = this.createRequest();
 
     let allowCallback = function() {
       let callback = function(aType, aContacts) {
         if (DEBUG) debug("got SIM contacts: " + aType + " " + JSON.stringify(aContacts));
         let result = aContacts.map(function(c) {
           var contact = new Contact();
-          contact.init( { name: [c.alphaId], tel: [ { number: c.number } ] } );
+          contact.init( { name: [c.alphaId], tel: [ { value: c.number } ] } );
           return contact;
         });
         if (DEBUG) debug("result: " + JSON.stringify(result));
         Services.DOMRequest.fireSuccess(request, result);
       };
       if (DEBUG) debug("getSimContacts " + aType);
 
       mRIL.getICCContacts(aType, callback);