You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@myfaces.apache.org by lu...@apache.org on 2010/06/08 23:08:57 UTC
svn commit: r952820 -
/myfaces/core/trunk/api/src/main/javascript/META-INF/resources/myfaces/_impl/core/_Runtime.js
Author: lu4242
Date: Tue Jun 8 21:08:57 2010
New Revision: 952820
URL: http://svn.apache.org/viewvc?rev=952820&view=rev
Log:
MYFACES-2745 Cannot set property "_mfProto" of null to "null" error with new javascript
Modified:
myfaces/core/trunk/api/src/main/javascript/META-INF/resources/myfaces/_impl/core/_Runtime.js
Modified: myfaces/core/trunk/api/src/main/javascript/META-INF/resources/myfaces/_impl/core/_Runtime.js
URL: http://svn.apache.org/viewvc/myfaces/core/trunk/api/src/main/javascript/META-INF/resources/myfaces/_impl/core/_Runtime.js?rev=952820&r1=952819&r2=952820&view=diff
==============================================================================
--- myfaces/core/trunk/api/src/main/javascript/META-INF/resources/myfaces/_impl/core/_Runtime.js (original)
+++ myfaces/core/trunk/api/src/main/javascript/META-INF/resources/myfaces/_impl/core/_Runtime.js Tue Jun 8 21:08:57 2010
@@ -61,7 +61,11 @@ if (!myfaces._impl.core._Runtime) {
//window extension with undefined behavior on our necks
//window.execScript does not return anything
//on htmlunit it return "null object"
- return window.execScript(code);
+ var ret = window.execScript(code);
+ if ('undefined' != typeof ret && ret == "null" /*htmlunit bug*/) {
+ return null;
+ }
+ return ret;
} else if (window.eval) {
//fix for a Mozilla bug, Mozilla prevents, that the window is properly applied