Use '===' instead of '=='. '==' is kinda dangerous in JavaScript.

Please refer http://javascript.crockford.com/code.html.