Details
-
Bug
-
Status: Closed
-
Major
-
Resolution: Fixed
-
3.5.0
-
None
Description
The current code checks to see if there's a non null, array, before iterating over config.configFileInjections, but...
function processResult(data, session) {
var widgetConfig = {};
...
//store any config-file element injections
widgetConfig.configFileInjections = _config_doc.findall("config-file");return widgetConfig;
function generateTabletXMLFile(session, config) {
...
//Inject any config-file modifications for bar-descriptor.xml
if (config.configFileInjections && Array.isArray(config.configFileInjections)) {
xmlDoc = new et.ElementTree(et.XML(xmlData));
config.configFileInjections.forEach(function (config_file) {
if (config_file.attrib["parent"] && config_file.attrib["target"] && config_file.attrib["target"] === "bar-descriptor.xml") {
xmlHelper.graftXML(xmlDoc, config_file._children, config_file.attrib["parent"]);
}
});
xmlData = xmlDoc.write({indent: 4});
}