cordova-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From vladimir-kotikov <>
Subject [GitHub] cordova-plugin-contacts pull request: CB-5308 Return rawId instead...
Date Fri, 27 Nov 2015 07:47:14 GMT
Github user vladimir-kotikov commented on a diff in the pull request:
    --- Diff: src/android/ ---
    @@ -1027,7 +1027,7 @@ else if (accounts.length > 1) {
         private String modifyContact(String id, JSONObject contact, String accountType, String
accountName) {
             // Get the RAW_CONTACT_ID which is needed to insert new values in an already
existing contact.
             // But not needed to update existing values.
    -        int rawId = (Integer.valueOf(getJsonString(contact, "rawId"))).intValue();
    +        String rawId = getJsonString(contact, "rawId");
    --- End diff --
    From my experiments this works both with `int` and `String`. My guess is that ContentProvider
casts types implicitly, when needed.
    Also, according to the [same documentation](
`id` is also of type `long`, but is has been used here as `String` always. So IMO it doesn't

If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at or file a JIRA ticket
with INFRA.

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message