Allow onCodeUpdate function to be defined in prototype chain.

This commit is contained in:
hns 2004-07-28 19:00:52 +00:00
parent 7ac392b088
commit f8d3f0e25d

View file

@ -262,7 +262,7 @@ public final class RhinoCore {
// If this prototype defines a postCompile() function, call it
Context cx = Context.getCurrentContext();
try {
Object fObj = op.get("onCodeUpdate",op);
Object fObj = ScriptableObject.getProperty(op, "onCodeUpdate");
if (fObj instanceof Function) {
((Function) fObj).call(cx, global, op, new Object[0]);
}