I was wondering if following syntax evaluates as I think it does :
Cluster.prototype.test_json_availability = function() {
return Modernizr.addTest('test_json', function() {
return (typeof $.browser.msie !== 'undefined' && $.browser.msie === true && $.browser.version < 7 && typeof window.JSON === 'undefined') ? false : true;
});
};
Let’s say I do use a MS browser, this means it will return true ? Or am I doing it wrong ?
You should transform the condition by applying De Morgan’s laws:
This will simplify the condition a lot, and you will be able to find the answer to your question.