Skip to content

Commit

Permalink
Fixed 'isNode' check to correctly work with browserify
Browse files Browse the repository at this point in the history
  • Loading branch information
Philip Shurpik authored and Philip Shurpik committed Mar 31, 2015
1 parent 4c3e6e8 commit eff9c27
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions lib/cmis.js
Original file line number Diff line number Diff line change
Expand Up @@ -22,8 +22,9 @@
var lib = {};

//check if we are running on node
var isNode = typeof module !== 'undefined' && module.exports;
if (isNode) {
var isCommonJSModules = typeof module !== 'undefined' && module.exports;
var isNode = isCommonJSModules && typeof window === 'undefined';
if (isCommonJSModules) {
module.exports = lib;
}
/**
Expand Down

0 comments on commit eff9c27

Please sign in to comment.