|
17 | 17 |
|
18 | 18 | import org.jetbrains.annotations.NotNull; |
19 | 19 | import org.jetbrains.annotations.Nullable; |
| 20 | +import org.labkey.api.util.XmlBeansUtil; |
20 | 21 | import org.labkey.test.BaseWebDriverTest; |
21 | 22 | import org.labkey.test.Locator; |
22 | 23 | import org.labkey.test.TestFileUtils; |
|
27 | 28 | import org.xml.sax.InputSource; |
28 | 29 |
|
29 | 30 | import javax.xml.parsers.DocumentBuilder; |
30 | | -import javax.xml.parsers.DocumentBuilderFactory; |
31 | 31 | import javax.xml.xpath.XPath; |
32 | 32 | import javax.xml.xpath.XPathConstants; |
33 | 33 | import javax.xml.xpath.XPathExpression; |
@@ -78,7 +78,7 @@ public void runPipelineAnalysis(@LoggedParam String importAction, String[] files |
78 | 78 | for (String file : files) |
79 | 79 | { |
80 | 80 | String directory = file.substring(0, file.lastIndexOf("/") + 1); |
81 | | - String fileName = file.substring(file.lastIndexOf("/") + 1, file.length()); |
| 81 | + String fileName = file.substring(file.lastIndexOf("/") + 1); |
82 | 82 | if (filePrefix == null) |
83 | 83 | { |
84 | 84 | filePrefix = directory; |
@@ -252,8 +252,7 @@ private Map<String, String> loadParameterMapFromXmlString(String xml) |
252 | 252 | { |
253 | 253 | try |
254 | 254 | { |
255 | | - DocumentBuilderFactory factory = DocumentBuilderFactory.newInstance(); |
256 | | - DocumentBuilder builder = factory.newDocumentBuilder(); |
| 255 | + DocumentBuilder builder = XmlBeansUtil.DOCUMENT_BUILDER_FACTORY.newDocumentBuilder(); |
257 | 256 | InputSource is = new InputSource(new StringReader(xml)); |
258 | 257 | Document doc = builder.parse(is); |
259 | 258 |
|
|
0 commit comments