code: function isLogicalIdentity(node, operator) {
              switch (node.type) {
                  case "Literal":
                      return (operator === "||" && node.value === true) ||
                             (operator === "&&" && node.value === false);
  
                  case "UnaryExpression":
                      return (operator === "&&" && node.operator === "void");
  
                  case "LogicalExpression":
                      return isLogicalIdentity(node.left, node.operator) ||
                               isLogicalIdentity(node.right, node.operator);
  
                  // no default
              }
              return false;
          }
docs: -------------------------------------------------------------------------- Helpers -------------------------------------------------------------------------- 
  Checks if a branch node of LogicalExpression short circuits the whole condition
  @param {ASTNode} node The branch of main condition which needs to be checked
  @param {string} operator The operator of the main LogicalExpression.
  @returns {boolean} true when condition short circuits whole condition