Fixed .unbind('.namespace').
authorScott González <scott.gonzalez@gmail.com>
Tue, 5 Feb 2008 19:32:00 +0000 (19:32 +0000)
committerScott González <scott.gonzalez@gmail.com>
Tue, 5 Feb 2008 19:32:00 +0000 (19:32 +0000)
src/event.js

index 9f384fb..927beda 100644 (file)
@@ -109,7 +109,7 @@ jQuery.event = {
 
                if ( events ) {
                        // Unbind all events for the element
-                       if ( types == undefined || types[0] == "." )
+                       if ( types == undefined || (typeof types == "string" && types.charAt(0) == ".") )
                                for ( var type in events )
                                        this.remove( elem, type + (types || "") );
                        else {