Check if prototype exists in hasFunction(...).
This commit is contained in:
parent
fab876e2e7
commit
47ab428371
1 changed files with 3 additions and 0 deletions
|
@ -395,6 +395,9 @@ public final class FesiEvaluator implements ScriptingEngine {
|
|||
String protoname = app.getPrototypeName (obj);
|
||||
try {
|
||||
ObjectPrototype op = getPrototype (protoname);
|
||||
// if this is an untyped object return false
|
||||
if (op == null)
|
||||
return false;
|
||||
ESValue func = op.getProperty (fname, fname.hashCode());
|
||||
if (func != null && func instanceof FunctionPrototype)
|
||||
return true;
|
||||
|
|
Loading…
Add table
Reference in a new issue