Replace '.' in action names with '_' to get a valid function name.
(Backport from helma.scripting.rhino in 1.3.0)
This commit is contained in:
parent
44e24b29d7
commit
57db6bd838
2 changed files with 6 additions and 1 deletions
|
@ -57,7 +57,7 @@ public class FesiActionAdapter {
|
||||||
|
|
||||||
Reader reader = null;
|
Reader reader = null;
|
||||||
|
|
||||||
functionName = action.getFunctionName();
|
functionName = action.getFunctionName().replace('.', '_');
|
||||||
sourceName = action.getSourceName();
|
sourceName = action.getSourceName();
|
||||||
|
|
||||||
try {
|
try {
|
||||||
|
|
|
@ -505,6 +505,8 @@ public class FesiEngine implements ScriptingEngine {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
functionName = functionName.replace('.', '_');
|
||||||
|
|
||||||
ESValue retval = eso.doIndirectCall(evaluator, eso, functionName, esv);
|
ESValue retval = eso.doIndirectCall(evaluator, eso, functionName, esv);
|
||||||
|
|
||||||
if (xmlrpc) {
|
if (xmlrpc) {
|
||||||
|
@ -572,6 +574,9 @@ public class FesiEngine implements ScriptingEngine {
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// replace '.' with '_' in function name
|
||||||
|
fname = fname.replace('.', '_');
|
||||||
|
|
||||||
ESValue func = op.getProperty(fname, fname.hashCode());
|
ESValue func = op.getProperty(fname, fname.hashCode());
|
||||||
|
|
||||||
if ((func != null) && func instanceof FunctionPrototype) {
|
if ((func != null) && func instanceof FunctionPrototype) {
|
||||||
|
|
Loading…
Add table
Reference in a new issue