Skip to content

typo needed to compare to 'undefined' not undefined - #547

Open
arush wants to merge 1 commit into
GoogleChrome:gh-pagesfrom
arush:patch-1
Open

arush wants to merge 1 commit into
GoogleChrome:gh-pagesfrom
arush:patch-1

Conversation

@arush

@arush arush commented Oct 16, 2017

Copy link
Copy Markdown

No description provided.

@arush

arush commented Oct 16, 2017

Copy link
Copy Markdown
Author

there's a typo in your comments. It happens to be a highly ranking page on google and i copy pasted the incorrect code only to find out it had a typo

// Test parameter values in the function body, specifying a default
to = to || 'DOM';
// OR if (typeof to === undefined) { to = 'DOM'; }
// OR if (typeof to === 'undefined') { to = 'DOM'; }

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

i think undefined is right, because comment says, if to is undefined then to = 'DOM'. means if to is falsy value undefined then assign 'dom' into to.

@beaufortfrancois
beaufortfrancois force-pushed the gh-pages branch 7 times, most recently from c198a70 to 03c4155 Compare November 26, 2022 06:50
@beaufortfrancois
beaufortfrancois force-pushed the gh-pages branch 5 times, most recently from 1de1b35 to c4f3954 Compare October 16, 2023 10:28
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