Skip to content

fixed typo #97

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
wants to merge 1 commit into from
Closed

fixed typo #97

wants to merge 1 commit into from

Conversation

coderaiser
Copy link
Contributor

variable $this was not used

variable $this was not used
@rodneyrehm
Copy link
Contributor

this is not a typo!

a) Your fix should have been $this instead of $($this), as the whole purpose is to avoid calling jQuery for no reason.
b) jQuery.filter() executes the callback in the scope of the currently evaluated element. That is why $(this) is totally correct here. Otherwise you'd be checking if the trigger element was fixed, instead of checking all it's parents.

Your "fix" is actually introducing a bug. Stuff like that happens to me all the time, too. Don't feel beat down - try again!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants