You are viewing a plain text version of this content. The canonical link for it is here.
Posted to xap-commits@incubator.apache.org by jm...@apache.org on 2007/07/10 00:26:16 UTC
svn commit: r554795 - /incubator/xap/trunk/codebase/src/xap/util/Hashtable.js
Author: jmargaris
Date: Mon Jul 9 17:26:15 2007
New Revision: 554795
URL: http://svn.apache.org/viewvc?view=rev&rev=554795
Log:
checking for both null and undefined
Modified:
incubator/xap/trunk/codebase/src/xap/util/Hashtable.js
Modified: incubator/xap/trunk/codebase/src/xap/util/Hashtable.js
URL: http://svn.apache.org/viewvc/incubator/xap/trunk/codebase/src/xap/util/Hashtable.js?view=diff&rev=554795&r1=554794&r2=554795
==============================================================================
--- incubator/xap/trunk/codebase/src/xap/util/Hashtable.js (original)
+++ incubator/xap/trunk/codebase/src/xap/util/Hashtable.js Mon Jul 9 17:26:15 2007
@@ -69,9 +69,9 @@
throw new xap.util.Exception( "key cannot be null in xap.util.Hashtable.containsKey()" );
}
key = this._computeKey(key);
+ var value = this._hashtable[key];
- //IMPORTANT if this is undefined that is a problem
- return this._hashtable[key]!=null;
+ return (value!=null && (typeof value != 'undefined'));
}
/**