1602 / compound

MVC framework. Built on Node.JS. Works on server and browser.
http://compoundjs.com
1.6k stars 183 forks source link

Consistent TypeOf #627

Open Anachron opened 10 years ago

Anachron commented 10 years ago

The code has mixed style between TypeOf something === function and function === TypeOf something.

https://github.com/1602/compound/blob/master/lib/controller-extensions.js#L137 https://github.com/1602/compound/blob/master/lib/controller-extensions.js#L304 https://github.com/1602/compound/blob/master/lib/controller-extensions.js#L307 https://github.com/1602/compound/blob/master/lib/compound.js#L167 https://github.com/1602/compound/blob/master/lib/compound.js#L257 https://github.com/1602/compound/blob/master/lib/compound.js#L264

Most are if (typeof VAR === 'function') { style. So it wouldn't hurt to stick to it.

fodor0205 commented 10 years ago

@Anachron You can freely open a pull request with your preferred style.

anatoliychakkaev commented 10 years ago

Should be 'typename' === typeof variablename

On 2 June 2014 14:22, Fodi69 notifications@github.com wrote:

@Anachron https://github.com/Anachron You can freely open a pull request with your preferred style.

— Reply to this email directly or view it on GitHub https://github.com/1602/compound/issues/627#issuecomment-44835902.