Index: lib/punycode.js |
diff --git a/lib/punycode.js b/lib/punycode.js |
index 58769d3bc4a854ec1dcfa00c00b8765b3df940ee..922669a30f65eff8028b7c675c80a21b6902bc5c 100644 |
--- a/lib/punycode.js |
+++ b/lib/punycode.js |
@@ -1,16 +1,6 @@ |
/*! http://mths.be/punycode v1.2.3 by @mathias */ |
/* Used under GPL 2.0, see https://github.com/bestiejs/punycode.js/blob/master/LICENSE-GPL.txt */ |
-;(function(root) { |
- |
- /** Detect free variables */ |
- var freeExports = typeof exports == 'object' && exports; |
- var freeModule = typeof module == 'object' && module && |
- module.exports == freeExports && module; |
- var freeGlobal = typeof global == 'object' && global; |
- if (freeGlobal.global === freeGlobal || freeGlobal.window === freeGlobal) { |
- root = freeGlobal; |
- } |
- |
+;(function() { |
/** |
* The `punycode` object. |
* @name punycode |
@@ -459,7 +449,7 @@ |
/*--------------------------------------------------------------------------*/ |
/** Define the public API */ |
- punycode = { |
+ exports = { |
/** |
* A string representing the current Punycode.js version number. |
* @memberOf punycode |
@@ -482,28 +472,4 @@ |
'toASCII': toASCII, |
'toUnicode': toUnicode |
}; |
- |
- /** Expose `punycode` */ |
- // Some AMD build optimizers, like r.js, check for specific condition patterns |
- // like the following: |
- if ( |
- typeof define == 'function' && |
- typeof define.amd == 'object' && |
- define.amd |
- ) { |
- define(function() { |
- return punycode; |
- }); |
- } else if (freeExports && !freeExports.nodeType) { |
- if (freeModule) { // in Node.js or RingoJS v0.8.0+ |
- freeModule.exports = punycode; |
- } else { // in Narwhal or RingoJS v0.7.0- |
- for (key in punycode) { |
- punycode.hasOwnProperty(key) && (freeExports[key] = punycode[key]); |
- } |
- } |
- } else { // in Rhino or a web browser |
- root.punycode = punycode; |
- } |
- |
-}(this)); |
+}()); |