Skip to content

Commit b4e5bc2

Browse files
therufainexorabletash
authored andcommitted
Recovered property accessor in encoding.js (Resolves inexorabletash#67)
Fixed issue described in inexorabletash/issues/67 The problem was casued by the missing propery accessor on the require statement, which passed the entire global scope of `encoding-indexes` instead of the indexes.
1 parent 053dc84 commit b4e5bc2

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

lib/encoding.js

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,8 @@
1111
// If we're in node require encoding-indexes and attach it to the global.
1212
if (typeof module !== "undefined" && module.exports &&
1313
!global["encoding-indexes"]) {
14-
global['encoding-indexes'] = require("./encoding-indexes.js");
14+
global["encoding-indexes"] =
15+
require("./encoding-indexes.js")["encoding-indexes"];
1516
}
1617

1718
//

0 commit comments

Comments
 (0)