diff --git a/modules/qrest/src/main/java/org/jpos/qrest/participant/Router.java b/modules/qrest/src/main/java/org/jpos/qrest/participant/Router.java index e91b136618..6b4feb9ad5 100644 --- a/modules/qrest/src/main/java/org/jpos/qrest/participant/Router.java +++ b/modules/qrest/src/main/java/org/jpos/qrest/participant/Router.java @@ -72,13 +72,14 @@ public String select(long id, Serializable context) { public void setConfiguration(Element e) throws ConfigurationException { try { for (Element r : e.getChildren("route")) { + String name = r.getAttributeValue("name"); routes.computeIfAbsent( r.getAttributeValue("method"), k -> new ArrayList<>()).add( new Route<>( r.getAttributeValue("path"), r.getAttributeValue("method"), - (t, s) -> r.getAttributeValue("name")) + (t, s) -> name) ); } } catch (Throwable t) {