Skip to content

Commit

Permalink
Merge pull request #11895 from brzpegasus/node-detection
Browse files Browse the repository at this point in the history
[BUGFIX beta] Properly detect if the environment is Node.
  • Loading branch information
stefanpenner committed Jul 26, 2015
2 parents 68719dd + 97b1a3d commit 6e00835
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion packages/loader/lib/main.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,8 @@ var define, requireModule, require, requirejs, Ember;
var mainContext = this;

(function() {
var isNode = typeof process !== 'undefined' && {}.toString.call(process) === '[object process]';
var isNode = typeof window === 'undefined' &&
typeof process !== 'undefined' && {}.toString.call(process) === '[object process]';

if (!isNode) {
Ember = this.Ember = this.Ember || {};
Expand Down

0 comments on commit 6e00835

Please sign in to comment.