Skip to content
Permalink
Browse files

accordion: simplified find-header-element code, thanks Ariel

  • Loading branch information
jzaefferer committed Jun 22, 2008
1 parent b876be0 commit dd584fbe9527c88e6adb40653224143abb6b4961
Showing with 2 additions and 3 deletions.
  1. +2 −3 ui/ui.accordion.js
@@ -179,9 +179,8 @@ function clickHandler(event) {

// due to the event delegation model, we have to check if one
// of the parent elements is our actual header, and find that
if ( clicked.parents(options.header).length ) {
clicked = clicked.parents(options.header + ":first");
}
// otherwise stick with the initial target
clicked = $( clicked.parents(options.header)[0] || clicked );

var clickedActive = clicked[0] == options.active[0];

0 comments on commit dd584fb

Please sign in to comment.
You can’t perform that action at this time.