public static boolean hasStrongNode(Node node) {
    try {
      node.getNodeType();
    } catch (Exception e) {
      return true;
    }
    if (node.getNodeType() == Node.TEXT_NODE) {
      return !node.getNodeValue().isEmpty();
    }
    if (node.getNodeName().equalsIgnoreCase("img")) {
      return true;
    }
    Node nextSibling, child = node.getFirstChild();
    while (child != null) {
      nextSibling = child.getNextSibling();
      if (child.getNodeType() == Node.TEXT_NODE) {
        if (child.getNodeValue() != null && !child.getNodeValue().isEmpty()) {
          return true;
        }
      } else if (child.getNodeName().equalsIgnoreCase("br") && nextSibling == null) {
        return !BRElement.as(child).getAttribute(DIRTY_ATTRIBUTE).equals("true");
      } else {
        return true;
      }
      child = child.getNextSibling();
    }
    return false;
  }