check for module before window for browserify support
Merge pull request #41 from mikefrey/browserify

Browserify Support