Commit a5fe3f60 authored by Richard van der Hoff's avatar Richard van der Hoff
Browse files

Fix a console error when importing in a browser

something about 'global' not defined
parent 2bb7f3b1
......@@ -2,7 +2,7 @@ var olm_exports = {};
var get_random_values;
var process; // Shadow the process object so that emscripten won't get
// confused by browserify
if (global && global["window"]) {
if (typeof(global) !== 'undefined' && global["window"]) {
// We're running with browserify
module["exports"] = olm_exports;
global["window"]["Olm"] = olm_exports;
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment