From ca9ce4d87d624843265a742c09ded1bb3ee02b1a Mon Sep 17 00:00:00 2001 From: Shaker Islam Date: Tue, 8 Apr 2014 14:47:45 -0500 Subject: [PATCH] stronger check on module --- nprogress.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/nprogress.js b/nprogress.js index f8b04f1..b93800a 100644 --- a/nprogress.js +++ b/nprogress.js @@ -3,7 +3,7 @@ ;(function(factory) { - if (typeof module === 'function') { + if (typeof module !== 'undefined' && module.exports) { module.exports = factory(); } else if (typeof define === 'function' && define.amd) { define(factory);