[Code Style] Rename shadowing variables

This commit is contained in:
Victor Woeltjen
2016-05-20 11:39:49 -07:00
parent e468080373
commit ad5691142e
56 changed files with 256 additions and 262 deletions

View File

@ -105,15 +105,15 @@ define(
// Check if an object has all capabilities designated as `needs`
// for a view. Exposing a capability via delegation is taken to
// satisfy this filter if `allowDelegation` is true.
function capabilitiesMatch(domainObject, capabilities, allowDelegation) {
var delegation = domainObject.getCapability("delegation");
function capabilitiesMatch(domainObj, capabilities, allowDelegation) {
var delegation = domainObj.getCapability("delegation");
allowDelegation = allowDelegation && (delegation !== undefined);
// Check if an object has (or delegates, if allowed) a
// capability.
function hasCapability(c) {
return domainObject.hasCapability(c) ||
return domainObj.hasCapability(c) ||
(allowDelegation && delegation.doesDelegateCapability(c));
}
@ -128,13 +128,13 @@ define(
// Check if a view and domain object type can be paired;
// both can restrict the others they accept.
function viewMatchesType(view, type) {
var views = type && (type.getDefinition() || {}).views,
function viewMatchesType(view, objType) {
var views = objType && (objType.getDefinition() || {}).views,
matches = true;
// View is restricted to a certain type
if (view.type) {
matches = matches && type && type.instanceOf(view.type);
matches = matches && objType && objType.instanceOf(view.type);
}
// Type wishes to restrict its specific views