Author: michiel
Date: 2010-02-17 13:29:47 +0100 (Wed, 17 Feb 2010)
New Revision: 41094

Modified:
   
mmbase/branches/MMBase-1_9/applications/taglib/src/main/java/org/mmbase/bridge/jsp/taglib/FieldInfoTag.java
Log:
field and datatype attributes used, and the field attribute was not correct, 
then the error message was was quite confusing.

Modified: 
mmbase/branches/MMBase-1_9/applications/taglib/src/main/java/org/mmbase/bridge/jsp/taglib/FieldInfoTag.java
===================================================================
--- 
mmbase/branches/MMBase-1_9/applications/taglib/src/main/java/org/mmbase/bridge/jsp/taglib/FieldInfoTag.java
 2010-02-17 11:35:06 UTC (rev 41093)
+++ 
mmbase/branches/MMBase-1_9/applications/taglib/src/main/java/org/mmbase/bridge/jsp/taglib/FieldInfoTag.java
 2010-02-17 12:29:47 UTC (rev 41094)
@@ -328,11 +328,14 @@
         Node          node = null;
         Field field;
         DataType dataType = getDataType();
+        String parentField = parentFieldId.getString(this);
         fieldProvider =
             "".equals(parentFieldId.getValue(this)) // field="" means 
explicitely don't use a field provider, so is not the same as omitting the 
attribue altogether
-            ? null : findFieldProvider(dataType == null);
+            ? null : findFieldProvider(dataType == null || 
parentField.length() > 0);
         if (fieldProvider == null) {
-            if (dataType == null) throw new JspTagException("No field provider 
found (" + parentFieldId + ") nor datatype specified");
+            if (dataType == null) {
+                throw new JspTagException("No field provider found (" + 
parentFieldId + ") nor datatype specified");
+            }
             final DataType dt = dataType;
             fieldProvider = new FieldProvider() {
                     private final Field f = new DataTypeField(getCloudVar(), 
dt);

_______________________________________________
Cvs mailing list
Cvs@lists.mmbase.org
http://lists.mmbase.org/mailman/listinfo/cvs

Reply via email to