Skip to content

Commit

Permalink
fix(root): use self as the root object when available
Browse files Browse the repository at this point in the history
  • Loading branch information
vsavkin committed Sep 11, 2015
1 parent ca42a32 commit 0428a85
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/util/root.ts
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ declare module NodeJS {
}
}

export var root = (objectTypes[typeof window] && window) || this;
export var root:any = (objectTypes[typeof self] && self) || (objectTypes[typeof window] && window);

var freeExports = objectTypes[typeof exports] && exports && !exports.nodeType && exports;
var freeModule = objectTypes[typeof module] && module && !module.nodeType && module;
Expand Down

0 comments on commit 0428a85

Please sign in to comment.