incubator-xap-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From mtu...@apache.org
Subject svn commit: r426762 - /incubator/xap/trunk/src/xap/xml/dom/XapElement.js
Date Sat, 29 Jul 2006 07:40:00 GMT
Author: mturyn
Date: Sat Jul 29 00:39:59 2006
New Revision: 426762

URL: http://svn.apache.org/viewvc?rev=426762&view=rev
Log:
Added test for a listener's existence before using it.

Modified:
    incubator/xap/trunk/src/xap/xml/dom/XapElement.js

Modified: incubator/xap/trunk/src/xap/xml/dom/XapElement.js
URL: http://svn.apache.org/viewvc/incubator/xap/trunk/src/xap/xml/dom/XapElement.js?rev=426762&r1=426761&r2=426762&view=diff
==============================================================================
--- incubator/xap/trunk/src/xap/xml/dom/XapElement.js (original)
+++ incubator/xap/trunk/src/xap/xml/dom/XapElement.js Sat Jul 29 00:39:59 2006
@@ -941,7 +941,9 @@
 		var listener = listeners[i];
 		
 		//TODO check for existence?
-		listener[methodName].call(listener, event);
+		if(listener[methodName]){
+			listener[methodName].call(listener, event);
+		}
 		
 		if ( listeners[i] != listener ) {
 			i = i - 1;



Mime
View raw message