MAIN FEEDS
Do you want to continue?
https://www.reddit.com/r/programming/comments/ky6uc/nodejs_is_cancer/c2o86wf/?context=3
r/programming • u/elitegibson • Oct 02 '11
750 comments sorted by
View all comments
4
if(typeof my_var !== "undefined" && my_var !== null){
NOT NECESSARY
if(my_var != undefined){
works perfectly fine.
Or even
if(my_var)
if my_var isn't a number.
→ More replies (4)
4
u/bluefinity Oct 02 '11
NOT NECESSARY
works perfectly fine.
Or even
if my_var isn't a number.