refactor: simplify process object initialization for sandboxed renderers (#14878)

Also fix `process.windowsStore`.
This commit is contained in:
Milan Burda 2018-09-30 23:24:00 +02:00 committed by Alexey Kuzmin
parent 0127bbc8e8
commit ce38be74df
5 changed files with 45 additions and 43 deletions

View file

@ -50,13 +50,4 @@ if (process.platform === 'win32') {
process.__defineGetter__('stdin', function () {
return stdin
})
// If we're running as a Windows Store app, __dirname will be set
// to C:/Program Files/WindowsApps.
//
// Nobody else get's to install there, changing the path is forbidden
// We can therefore say that we're running as appx
if (__dirname.includes('\\WindowsApps\\')) {
process.windowsStore = true
}
}