Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
function quickSubset(queryA, queryB){
return set.isSubset( new QueryLogic.KeysAnd(queryA), new QueryLogic.KeysAnd(queryB) );
}
function quickEqual(queryA, queryB){
var dataA = queryA.data,
dataB = queryB.data;
if(dataA && dataB) {
if(!deepMatches(dataA, dataB)) {
return false;
}
}
var q1 = new QueryLogic.KeysAnd(removeFixtureAndXHR(queryA)),
q2 = new QueryLogic.KeysAnd(removeFixtureAndXHR(queryB));
return set.isEqual( q1, q2 );
}
function quickEqual(queryA, queryB){
var dataA = queryA.data,
dataB = queryB.data;
if(dataA && dataB) {
if(!deepMatches(dataA, dataB)) {
return false;
}
}
var q1 = new QueryLogic.KeysAnd(removeFixtureAndXHR(queryA)),
q2 = new QueryLogic.KeysAnd(removeFixtureAndXHR(queryB));
return set.isEqual( q1, q2 );
}
function makeComparatorType(compare) {
var Type = function(){};
var SetType = function(value) {
this.value = value;
};
SetType.prototype.isMember = function(value, root, keys){
return compare(this.value, value, root, keys);
};
canReflect.assignSymbols(Type,{
"can.SetType": SetType
});
set.defineComparison(SetType,SetType, identityComparitor);
set.defineComparison(set.UNIVERSAL,SetType,{
difference: function(){
return set.UNDEFINABLE;
}
});
return Type;
}
function makeComparatorType(compare) {
var Type = function(){};
var SetType = function(value) {
this.value = value;
};
SetType.prototype.isMember = function(value, root, keys){
return compare(this.value, value, root, keys);
};
canReflect.assignSymbols(Type,{
"can.SetType": SetType
});
set.defineComparison(SetType,SetType, identityComparitor);
set.defineComparison(set.UNIVERSAL,SetType,{
difference: function(){
return set.UNDEFINABLE;
}
});
return Type;
}
difference: function(){
return set.UNDEFINABLE;
}
});
function quickEqual(queryA, queryB){
var dataA = queryA.data,
dataB = queryB.data;
if(dataA && dataB) {
if(!deepMatches(dataA, dataB)) {
return false;
}
}
var q1 = new QueryLogic.KeysAnd(removeFixtureAndXHR(queryA)),
q2 = new QueryLogic.KeysAnd(removeFixtureAndXHR(queryB));
return set.isEqual( q1, q2 );
}
function identityIntersection(v1, v2) {
return v1.value === v2.value ? v1 : set.EMPTY;
}
function identityDifference(v1, v2){