Browse Source

comment re potential redundant eval

pull/2/head
gorhill 10 years ago
parent
commit
0174955287
  1. 6
      src/js/matrix.js

6
src/js/matrix.js

@ -399,6 +399,12 @@ Matrix.prototype.evaluateCellZXY = function(srcHostname, desHostname, type) {
return Matrix.GreenIndirect;
}
// TODO: There are cells evaluated twice when the type is '*'. Unsure
// whether it's worth trying to avoid that, as this could introduce
// overhead which may not be gained back by skipping the redundant tests.
// And this happens *only* when building the matrix UI, not when
// evaluating net requests.
// Specific-hostname specific-type cell
var r = this.evaluateCellZ(srcHostname, desHostname, type);
if ( r === 1 ) { return Matrix.RedDirect; }

Loading…
Cancel
Save