no good reason to prevent scopable literal "1st-party"

pull/2/head
gorhill 10 years ago
parent cd7996fb7d
commit 5f63a0f984

@ -364,12 +364,12 @@ Matrix.prototype.evaluateCellZXY = function(srcHostname, desHostname, type) {
// 1st-party specific-type cell: it's a special row, it exists only in
// global scope.
r = this.evaluateCellZ('*', '1st-party', type);
r = this.evaluateCellZ(srcHostname, '1st-party', type);
if ( r === 1 ) { return Matrix.RedIndirect; }
if ( r === 2 ) { return Matrix.GreenIndirect; }
// Do not override narrower rule
if ( rl !== 2 ) {
rl = this.evaluateCellZ('*', '1st-party', '*');
rl = this.evaluateCellZ(srcHostname, '1st-party', '*');
if ( rl === 1 ) { return Matrix.RedIndirect; }
}
}

@ -120,7 +120,7 @@ var matrixSnapshot = function(details) {
// These rows always exist
r.rows['*'] = new RowSnapshot(r.scope, '*', '*');
r.rows['1st-party'] = new RowSnapshot('*', '1st-party', '1st-party');
r.rows['1st-party'] = new RowSnapshot(r.scope, '1st-party', '1st-party');
r.rowCount += 1;
var µmuri = µm.URI;

@ -345,10 +345,9 @@ function handleFilter(button, leaning) {
var cell = button.ancestors('div.matCell');
var type = cell.prop('reqType');
var desHostname = cell.prop('hostname');
var srcHostname = desHostname !== '1st-party' ? matrixSnapshot.scope : '*';
var request = {
what: getCellAction(desHostname, type, leaning),
srcHostname: srcHostname,
srcHostname: matrixSnapshot.scope,
desHostname: desHostname,
type: type
};

Loading…
Cancel
Save