Fix AMD detection condition, as per umdjs/umd/commonjsStrictGlobal.js

This worked fine in the browser using require.js, but I couldn't get it to run in our node test suite until I modified this. This brings the module inline with many other AMD modules and the umdjs examples. See: https://github.com/umdjs/umd/blob/master/commonjsStrictGlobal.js