Skip to content
This repository has been archived by the owner on Nov 30, 2021. It is now read-only.

Commit

Permalink
Merge pull request #295 from schester44/fix/global-assumption
Browse files Browse the repository at this point in the history
Adds an additional typeof check for the global.moment instance
  • Loading branch information
urish authored Aug 9, 2017
2 parents 25aef52 + de11fa0 commit 843f6fe
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion angular-moment.js
Original file line number Diff line number Diff line change
Expand Up @@ -732,6 +732,6 @@
} else if (typeof module !== 'undefined' && module && module.exports && (typeof require === 'function') && !isElectron) {
module.exports = angularMoment(require('angular'), require('moment'));
} else {
angularMoment(angular, (typeof global !== 'undefined' ? global : window).moment);
angularMoment(angular, (typeof global !== 'undefined' && typeof global.moment !== 'undefined' ? global : window).moment);
}
})();

0 comments on commit 843f6fe

Please sign in to comment.