Setting ContactFindOptions to correct defaults

This commit is contained in:
macdonst 2010-10-19 00:27:21 +08:00
parent f15bdf9445
commit bc086cb93d
3 changed files with 6 additions and 6 deletions

View File

@ -111,8 +111,8 @@ Contacts.prototype.create = function(properties) {
var ContactFindOptions = function(filter, multiple, limit, updatedSince) {
this.filter = filter || '';
this.multiple = multiple || true;
this.limit = limit || Number.MAX_VALUE;
this.multiple = multiple || false;
this.limit = limit || 1;
this.updatedSince = updatedSince || '';
};

View File

@ -82,8 +82,8 @@ public class ContactAccessorSdk3_4 extends ContactAccessor {
@Override
public JSONArray search(JSONArray filter, JSONObject options) {
String searchTerm = "";
int limit = Integer.MAX_VALUE;
boolean multiple = true;
int limit = 1;
boolean multiple = false;
try {
searchTerm = options.getString("filter");
if (searchTerm.length()==0) {

View File

@ -114,8 +114,8 @@ public class ContactAccessorSdk5 extends ContactAccessor {
// Get the find options
String searchTerm = "";
int limit = Integer.MAX_VALUE;
boolean multiple = true;
int limit = 1;
boolean multiple = false;
try {
searchTerm = options.getString("filter");
if (searchTerm.length()==0) {