# HG changeset patch # User Sascha L. Teichmann # Date 1379684679 -7200 # Node ID a2abd87c0d3b0e44a4c8fdcdd7d21769c51a0b39 # Parent beb9e94f04d3a8aa3bdd5d146e24ce4a4c31d7fa Trim "names" and "class" attribute of out generators before using. diff -r beb9e94f04d3 -r a2abd87c0d3b artifacts/doc/conf/conf.xml --- a/artifacts/doc/conf/conf.xml Fri Sep 20 15:42:21 2013 +0200 +++ b/artifacts/doc/conf/conf.xml Fri Sep 20 15:44:39 2013 +0200 @@ -285,13 +285,13 @@ - - - - - - - < + + + + + + + @@ -305,95 +305,95 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + - - - - - - - - - - + + + + + + + + + + - - - - + + + + diff -r beb9e94f04d3 -r a2abd87c0d3b artifacts/src/main/java/org/dive4elements/river/artifacts/context/RiverContextFactory.java --- a/artifacts/src/main/java/org/dive4elements/river/artifacts/context/RiverContextFactory.java Fri Sep 20 15:42:21 2013 +0200 +++ b/artifacts/src/main/java/org/dive4elements/river/artifacts/context/RiverContextFactory.java Fri Sep 20 15:44:39 2013 +0200 @@ -332,10 +332,10 @@ for (int i = 0; i < num; i++) { Element item = (Element)outGenerators.item(i); - String name = item.getAttribute("names"); - String clazz = item.getAttribute("class"); + String names = item.getAttribute("names").trim(); + String clazz = item.getAttribute("class").trim(); - if (name.isEmpty() || clazz.isEmpty()) { + if (names.isEmpty() || clazz.isEmpty()) { continue; } @@ -352,7 +352,7 @@ Pair, Element> pair = new Pair, Element>(generatorClass, item); - for (String key: name.split("[\\s,]")) { + for (String key: names.split("[\\s,]")) { if (!(key = key.trim()).isEmpty()) { generators.put(key, pair); idx++;