One solution might be to have both files part of the same message. You could do this by loading the xml contents in to a JSON object. You could probably do the same by loading both files into a single XML message, but I find JSON to be cleaner since you don't have to deal with the prolog nested in the XML.
var bothFiles = {};
bothFiles.firstFile = '' + firstFileContents;
bothFiles.secondFile = '' + secondFileContents;
qie.addInboundMessage(JSON.stringify(bothFiles), fileName);
Then within your mappings, you have access to both files in a synchronous way:
var jsonMessage = JSON.parse(message.getNode('/'));
var firstXml = qie.parseXmlString(jsonMessage.firstFile);
var secondXml = qie.parseXmlString(jsonMessage.secondFile);
As you branch using your condition node, you can change the message type to xml and set it to which file you need to write. You can route to two mapping nodes... one sets first as the message, the other sets the second as the message:
var jsonMessage = JSON.parse(message.getNode('/'));
message = qie.createXmlMessage(jsonMessage.firstFile); // for the firstFile