Update of /var/cvs/applications/richtext/src/org/mmbase/richtext/processors/xml
In directory james.mmbase.org:/tmp/cvs-serv15802
Modified Files:
Wiki.java
Log Message:
this imporoves on creatign duplicate relations
See also:
http://cvs.mmbase.org/viewcvs/applications/richtext/src/org/mmbase/richtext/processors/xml
Index: Wiki.java
===================================================================
RCS file:
/var/cvs/applications/richtext/src/org/mmbase/richtext/processors/xml/Wiki.java,v
retrieving revision 1.7
retrieving revision 1.8
diff -u -b -r1.7 -r1.8
--- Wiki.java 27 Apr 2008 04:26:56 -0000 1.7
+++ Wiki.java 30 Apr 2008 12:17:03 -0000 1.8
@@ -28,7 +28,7 @@
* id of the node).
*
* @author Michiel Meeuwissen
- * @version $Id: Wiki.java,v 1.7 2008/04/27 04:26:56 michiel Exp $
+ * @version $Id: Wiki.java,v 1.8 2008/04/30 12:17:03 michiel Exp $
* @todo something goes wrong if same node relation multiple times.
*/
@@ -39,7 +39,11 @@
private static final long serialVersionUID = 1L;
/**
- * Searches in the existsing relations for a relation with the given id
+ * Searches in the existsing relations for a relation with the
+ * given id
+ * @param a The anchor which we are trying to match
+ * @param links List of alreayd existing relation objects
+ * @param id (of a)
*/
Node findById(Element a, NodeList links, String id) {
NodeIterator ni = links.nodeIterator();
@@ -49,7 +53,8 @@
log.debug("Id in " + relation.getNumber() + " " + relId + "
comparing with '" + id);
if (! "".equals(relId)) {
String decorId = decorateId(id);
- if (relId.equals(decorId)) {
+ String decorRelId = decorateId(relId);
+ if (relId.equals(decorId) || relId.equals(decorRelId)) {
log.debug(relId + "==" + decorId);
return relation;
} else {
_______________________________________________
Cvs mailing list
[email protected]
http://lists.mmbase.org/mailman/listinfo/cvs