Draggable: _isValidTarget returning boolean

This commit is contained in:
Dave Stein 2013-02-24 18:56:02 -05:00
parent d32183edc4
commit 78500111da

View File

@ -77,7 +77,8 @@ $.widget( "ui.draggable", $.ui.interaction, {
var handle = this.options.handle ? element.closest( this.options.handle ).length : true, var handle = this.options.handle ? element.closest( this.options.handle ).length : true,
exclude = this.options.exclude ? element.closest( this.options.exclude ).length : false; exclude = this.options.exclude ? element.closest( this.options.exclude ).length : false;
return ( handle && !exclude ); // Enforce boolean
return !!( handle && !exclude );
}, },
_start: function( event, pointerPosition ) { _start: function( event, pointerPosition ) {