private static boolean canHaveAttributes(XmlElementDescriptor descriptor, XmlTag context) {
    XmlAttributeDescriptor[] attributes = descriptor.getAttributesDescriptors(context);
    int required = WebEditorOptions.getInstance().isAutomaticallyInsertRequiredAttributes() ?
                   ArraysKt.count(attributes, (attribute) -> attribute.isRequired() && context.getAttribute(attribute.getName()) == null) :
                   0;
    return attributes.length - required > 0 ;
  }
private static boolean canHaveAttributes(XmlElementDescriptor descriptor, XmlTag context)