Better HN
topnewbestaskshowjobs
Log inSign up

paracaidista

5 karma · joined Nov 29, 2014 (12y ago) · 3 submissions

Submissions

comment 11y ago · link · parent

== vs. === aside, it's a bit hypocritical to use === because it's safer when you're using undefined as a keyword. You can't tell just from looking at that line whether the variable undefined is actually undefined or not; it could, in fact, be defined (below the global scope, that is -- unless you're in an older browser, I suppose).

Granted, defining a variable called undefined would be absurd, and I realize I'm nitpicking here, but if we're trying to make a point about good practice, typeof would be the way to go. (Of course, more often you only really care if something == null or not, so you'd just do a simple == null check, like you said.)

comment 11y ago · link · parent

For those interested, I believe §121.542(d) is the regulation they're referring to when they say the FAA has prohibited electronic devices. http://rgl.faa.gov/Regulatory_and_Guidance_Library/rgFAR.nsf...

Part 121 of course only applies to airliners. For non-commercial flights, only §91.21 would apply, which is far less prohibitive. http://www.ecfr.gov/cgi-bin/text-idx?node=14:2.0.1.3.10.1.4....

comment 12y ago · link · parent

I noticed those release names, too! Made my day.