diff --git a/gun.js b/gun.js index 7351d3aa..0b8bac67 100644 --- a/gun.js +++ b/gun.js @@ -980,7 +980,8 @@ }({})); if(typeof window !== "undefined"){ window.Gun = Gun; - } else { + } + if(typeof module !== 'undefined' && module.exports){ module.exports = Gun; } var root = this || {}; // safe for window, global, root, and 'use strict'.