mirror of
https://github.com/jquery/jquery-ui.git
synced 2026-04-20 03:02:41 -04:00
Menu: Ensure an event was passed before checking its type. Fixes #9384 - Menu: _focus function forgets null check with doing a pattern match on event.type
This commit is contained in:
2
ui/jquery.ui.menu.js
vendored
2
ui/jquery.ui.menu.js
vendored
@@ -389,7 +389,7 @@ $.widget( "ui.menu", {
|
||||
}
|
||||
|
||||
nested = item.children( ".ui-menu" );
|
||||
if ( nested.length && ( /^mouse/.test( event.type ) ) ) {
|
||||
if ( nested.length && event && ( /^mouse/.test( event.type ) ) ) {
|
||||
this._startOpening(nested);
|
||||
}
|
||||
this.activeMenu = item.parent();
|
||||
|
||||
Reference in New Issue
Block a user