NebulousLabs / Sia-UI

A Graphical Frontend for Sia - https://sia.tech
MIT License
389 stars 109 forks source link

Check env for app.html entry #801

Closed eddiewang closed 6 years ago

eddiewang commented 6 years ago

This fixes the white-screen problem on the latest RC build. I enabled a debug tool and noticed that electron was trying to load file://app.html. This is because it's using process.cwd() which is necessary in dev mode, but breaks in prod mode.

I added a flag to check the node env, and then use app.getAppPath() instead of process.cwd() for production builds.