From 69cdc2ccd044a3adc75b20447254465b5cc0df87 Mon Sep 17 00:00:00 2001 From: Tom Robinson Date: Thu, 8 Oct 2009 21:41:35 -0700 Subject: [PATCH] Check for "system", fixes press. --- Objective-J/evaluate.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Objective-J/evaluate.js b/Objective-J/evaluate.js index 50a902d63..02e33aaf3 100644 --- a/Objective-J/evaluate.js +++ b/Objective-J/evaluate.js @@ -159,7 +159,7 @@ function fragment_evaluate_code(aFragment) { #if RHINO var functionText = "function(){"+GET_CODE(aFragment)+"/**/\n}"; - if (system.engine === "rhino") + if (typeof system !== "undefined" && system.engine === "rhino") compiled = Packages.org.mozilla.javascript.Context.getCurrentContext().compileFunction(window, functionText, GET_FILE(aFragment).path, 0, null); else compiled = eval(functionText);