Skip to content

Commit

Permalink
fix useless condition (#2840)
Browse files Browse the repository at this point in the history
without parens the argument to `hasClass` included the `or ...` clause

fixes #2833
  • Loading branch information
koenpunt authored Jun 21, 2017
1 parent 0d739b8 commit 6cfe4c9
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion coffee/chosen.jquery.coffee
Original file line number Diff line number Diff line change
Expand Up @@ -299,7 +299,7 @@ class Chosen extends AbstractChosen
this.result_do_highlight( target ) if target

search_results_mouseout: (evt) ->
this.result_clear_highlight() if $(evt.target).hasClass "active-result" or $(evt.target).parents('.active-result').first()
this.result_clear_highlight() if $(evt.target).hasClass("active-result") or $(evt.target).parents('.active-result').first()

choice_build: (item) ->
choice = $('<li />', { class: "search-choice" }).html("<span>#{this.choice_label(item)}</span>")
Expand Down

0 comments on commit 6cfe4c9

Please sign in to comment.