aboutsummaryrefslogtreecommitdiffstats
path: root/ui/widgets/button.js
diff options
context:
space:
mode:
Diffstat (limited to 'ui/widgets/button.js')
-rw-r--r--ui/widgets/button.js3
1 files changed, 2 insertions, 1 deletions
diff --git a/ui/widgets/button.js b/ui/widgets/button.js
index 42cfec06d..3def0f9aa 100644
--- a/ui/widgets/button.js
+++ b/ui/widgets/button.js
@@ -373,7 +373,8 @@ if ( $.uiBackCompat !== false ) {
"attempted to call method '" + options + "'" );
}
- if ( !$.isFunction( instance[ options ] ) || options.charAt( 0 ) === "_" ) {
+ if ( typeof instance[ options ] !== "function" ||
+ options.charAt( 0 ) === "_" ) {
return $.error( "no such method '" + options + "' for button" +
" widget instance" );
}