lib/rules/accessor-pairs.js
function isArgumentOfMethodCall(node, index, object, property) {
    const parent = node.parent;

    return (
        parent.type === "CallExpression" &&
        parent.callee.type === "MemberExpression" &&
        parent.callee.computed === false &&
        isIdentifier(parent.callee.object, object) &&
        isIdentifier(parent.callee.property, property) &&
        parent.arguments[index] === node
    );
}
function isArgumentOfMethodCall(node, index, object, property) {
    const parent = node.parent;

    return (
        parent.type === "CallExpression" &&
        parent.callee.type === "MemberExpression" &&
        parent.callee.computed === false &&
        isIdentifier(parent.callee.object, object) &&
        isIdentifier(parent.callee.property, property) &&
        parent.arguments[index] === node
    );
}
function isArgumentOfMethodCall ( node , index , object , property ) { const parent = node . parent ; return ( parent . type === "CallExpression" && parent . callee . type === "MemberExpression" && parent . callee . computed === false && isIdentifier ( parent . callee . object , object ) && isIdentifier ( parent . callee . property , property ) && parent . arguments [ index ] === node ) ; }
Checks whether or not a given node is an argument of a specified method call.
@param {ASTNode} node - A node to check.
@param {number} index - An expected index of the node in arguments.
@param {string} object - An expected name of the object of the method.
@param {string} property - An expected name of the method.
@returns {boolean} `true` if the node is an argument of the specified method call.
Checks whether or not a given node is an argument of a specified method call .