Merge pull request #152 from marvinhagemeister/fix_commonjs

Swap CommonJS and AMD module check so that CommonJS is checked first
This commit is contained in:
Sam Potts
2016-01-27 08:45:10 +11:00
2 changed files with 6 additions and 6 deletions

4
dist/plyr.js vendored

File diff suppressed because one or more lines are too long

View File

@ -11,12 +11,12 @@
'use strict';
/*global define,module*/
if (typeof define === 'function' && define.amd) {
// AMD
define(null, function() { factory(root, document) });
} else if (typeof module === 'object') {
if (typeof module === 'object' && typeof module.exports === 'object') {
// Node, CommonJS-like
module.exports = factory(root, document);
} else if (typeof define === 'function' && define.amd) {
// AMD
define(null, function() { factory(root, document) });
} else {
// Browser globals (root is window)
root.plyr = factory(root, document);