mawie81 / electron-oauth2

A library to handle OAuth2 authentication for your Electron app.
MIT License
99 stars 56 forks source link

Updating require for BrowserWindow to Work #3

Closed program247365 closed 8 years ago

program247365 commented 8 years ago

This fixes for latest Electron: 1.1.1

On latest Electron, immediately when requiring this module got:

Error:
> electron .

App threw an error when running TypeError: Cannot read property 'BrowserWindow' of undefined
    at Object.<anonymous> (/app/node_modules/electron-oauth2/index.js:6:51)
    at Module._compile (module.js:541:32)
    at Object.Module._extensions..js (module.js:550:10)
    at Module.load (module.js:456:32)
    at tryModuleLoad (module.js:415:12)
    at Function.Module._load (module.js:407:3)
    at Module.require (module.js:466:17)
    at require (internal/module.js:20:19)
    at Object.<anonymous> (/app/index.js:5:24)
    at Module._compile (module.js:541:32)
mawie81 commented 8 years ago

Thx for the fix 👍

program247365 commented 8 years ago

Welcome!