cosmetic changes; fix semicolons

This commit is contained in:
rolux 2014-08-19 10:18:49 +02:00
parent e56333523b
commit 9f2dc33124

View file

@ -318,7 +318,7 @@ Ox.api = function(items, options) {
return Ox.sortBy(array, by, map); return Ox.sortBy(array, by, map);
}, { }, {
key: function(args) { key: function(args) {
return JSON.stringify([args[1], args[3]]) return JSON.stringify([args[1], args[3]]);
} }
}); });
@ -419,11 +419,9 @@ Ox.api = function(items, options) {
function testQuery(item, query) { function testQuery(item, query) {
var match = true; var match = true;
Ox.forEach(query.conditions, function(condition) { Ox.forEach(query.conditions, function(condition) {
if (condition.conditions) { match = (
match = testQuery(item, condition); condition.conditions ? testQuery : testCondition
} else { )(item, condition);
match = testCondition(item, condition)
}
if ( if (
(query.operator == '&' && !match) (query.operator == '&' && !match)
|| (query.operator == '|' && match) || (query.operator == '|' && match)
@ -472,7 +470,7 @@ Ox.find = function(array, string, leading) {
index > -1 && matches[index == 0 ? 0 : 1][ index > -1 && matches[index == 0 ? 0 : 1][
lowerCase == string ? 'unshift' : 'push' lowerCase == string ? 'unshift' : 'push'
](value); ](value);
}) });
return leading ? matches[0] : matches[0].concat(matches[1]); return leading ? matches[0] : matches[0].concat(matches[1]);
}; };