function findReference(scope, node) {
    const references = scope.references.filter(
        reference =>
            reference.identifier.range[0] === node.range[0] &&
            reference.identifier.range[1] === node.range[1]
    )

    /* istanbul ignore else: correctly returns null */
    if (references.length === 1) {
        return references[0]
    }
    return null
}
Finds the eslint-scope reference in the given scope.
@param {Object} scope The scope to search.
@param {ASTNode} node The identifier node.
@returns {Reference|null} Returns the found reference or null if none were found.