docs: function _xmlFileSet(file, element, attributeMapping, options) {
    const doc = loadXmlFile(file, options);
    const node = getXmlNode(doc, element);
    const result = [];
  
    if (_.isReallyObject(attributeMapping)) {
      _.each(attributeMapping, (value, attributeName) => {
        if (_.isFunction(value)) {
          result.push(value(node.getAttributeNode(attributeName)));
        } else {
          if (_.isNull(value)) {
            node.removeAttribute(attributeName);
          } else {
            node.setAttribute(attributeName, value);
          }
        }
      });
    } else {
      // still being able to provide the node to pass the node to a given function
      if (_.isFunction(attributeMapping)) {
        result.push(attributeMapping(node, doc));
      } else {
        if (node.hasChildNodes()) {
          let i = 0;
          const nNodes = node.childNodes.length;
          while (i < nNodes) {
            node.removeChild(i);
            i++;
          }
        }
        // if attribute and value == null, delete the node
        if (_.isNull(attributeMapping)) {
          node.parentNode.removeChild(node);
        } else {
          node.appendChild(doc.createTextNode(attributeMapping));
        }
      }
    }
    write(file, new XMLSerializer().serializeToString(doc), options);
    if (!_.isEmpty(result)) {
      return (result.length > 1) ? result : result[0];
    }
  }