[open-ils-commits] r9354 - trunk/Open-ILS/web/js/dojo/openils

svn at svn.open-ils.org svn at svn.open-ils.org
Mon Apr 14 17:00:15 EDT 2008


Author: erickson
Date: 2008-04-14 16:22:14 -0400 (Mon, 14 Apr 2008)
New Revision: 9354

Modified:
   trunk/Open-ILS/web/js/dojo/openils/Event.js
Log:
checking to make sure the potential event is actually an object before using the "in" operator

Modified: trunk/Open-ILS/web/js/dojo/openils/Event.js
===================================================================
--- trunk/Open-ILS/web/js/dojo/openils/Event.js	2008-04-14 20:21:49 UTC (rev 9353)
+++ trunk/Open-ILS/web/js/dojo/openils/Event.js	2008-04-14 20:22:14 UTC (rev 9354)
@@ -45,7 +45,7 @@
      * null is returned
      */
     openils.Event.parse = function(evt) {
-        if(evt && 'ilsevent' in evt && 'textcode' in evt)
+        if(evt && typeof evt == 'object' && 'ilsevent' in evt && 'textcode' in evt)
             return new openils.Event(evt);
         return null;
     }



More information about the open-ils-commits mailing list