cordova-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Filip Maj (JIRA)" <j...@apache.org>
Subject [jira] [Resolved] (CB-1931) Contact.find() docs don't match implementation for zero-length array
Date Fri, 22 Feb 2013 19:18:13 GMT

     [ https://issues.apache.org/jira/browse/CB-1931?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]

Filip Maj resolved CB-1931.
---------------------------

       Resolution: Fixed
    Fix Version/s: 2.5.0

Fixed in https://git-wip-us.apache.org/repos/asf?p=cordova-docs.git;a=commit;h=888deeaacb24eb5bbd460ec53f1ce3f413e792e4

Should land in 2.5.0rc2 or 2.5.0 proper.
                
> Contact.find() docs don't match implementation for zero-length array
> --------------------------------------------------------------------
>
>                 Key: CB-1931
>                 URL: https://issues.apache.org/jira/browse/CB-1931
>             Project: Apache Cordova
>          Issue Type: Bug
>          Components: CordovaJS, Docs
>            Reporter: Andrew Grieve
>            Assignee: Filip Maj
>            Priority: Minor
>             Fix For: 2.5.0
>
>
> The docs say:
> http://docs.phonegap.com/en/2.2.0/cordova_contacts_contacts.md.html#contacts.find
> A zero-length contactFields parameter will result in an array of Contact objects with
only the id property populated.
> The code says (in contacts.js):
> if (!fields || (utils.isArray(fields) && fields.length === 0)) {
>   errorCB && errorCB(new ContactError(ContactError.INVALID_ARGUMENT_ERROR));
> }
> I peeked at the iOS Contacts impl, and I don't think it looks for the case of an empty
array.
> Maybe simplest thing is to just make the docs say that an empty array is invalid?

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

Mime
View raw message