def safeGetAttr(node, attrName):
    """
    Return an attribute from a node by name.
    Returns None if the attribute does not exist.

    Args:
        node (PyNode): The node with the attribute
        attrName (str): The attribute name
    """
    if node.hasAttr(attrName):
        return node.attr(attrName)