PropertyFile coercion bugfix
[org.ibex.core.git] / src / org / ibex / js / PropertyFile.java
index 4e8542f..c60e43d 100644 (file)
@@ -20,6 +20,7 @@ public class PropertyFile extends JS {
         public String coerceToString()  { return (String)p.get(prefix.substring(0, prefix.length() - 1)); }
         public Enumeration keys() throws JSExn { throw new JSExn("PropertyFile.keys() not supported"); }
         public Object get(Object key) throws JSExn {
+            if (toString(key).equals("")) return coerceToString();
             Object ret = p.get(prefix + escape(toString(key)));
             if (ret != null) return ret;
             return new Minion(prefix + escape(toString(key)) + ".");