Skip to content
This repository has been archived by the owner on Jun 28, 2022. It is now read-only.

Rmv invoking parens on callback #10

Closed
wants to merge 1 commit into from
Closed

Rmv invoking parens on callback #10

wants to merge 1 commit into from

Conversation

prather-mcs
Copy link
Contributor

In two places you wrap an anonymous function in $(), for the stated
purpose of ensuring that the code in the function waits until browser
ready before executing, however you invoke the anonymous function with
parentheses.

This means that the code in the function will immediately execute, and
the return value of the function will be given to $(). Since the
return value is not a function, this contradicts the correct usage of
the jQuery method, and contradicts the stated purpose of using $().

Review on Reviewable

In two places you wrap an anonymous function in `$()`, for the stated
purpose of ensuring that the code in the function waits until browser
ready before executing, however you invoke the anonymous function with
parentheses.

This means that the code in the function will immediately execute, and
the return value of the function will be given to `$()`. Since the
return value is not a function, this contradicts the correct usage of
the jQuery method, and contradicts the stated purpose of using $().
@walesmd
Copy link
Contributor

walesmd commented Dec 3, 2015

Pull requests includes syntax errors (non-matching parens). The way it's currently done has no negative impact on how the application runs, going to leave this as is.

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

Successfully merging this pull request may close these issues.

None yet

2 participants