Fix platform detection
This commit is contained in:
@@ -617,17 +617,20 @@ ipcMain.on(Constants.IPC_Get_Platform, (event) => {
|
||||
.then(data => {
|
||||
platform = data.replace(/(\r\n|\n|\r)/gm,"");
|
||||
event.sender.send(Constants.IPC_Get_Platform_Reply, {
|
||||
data: platform,
|
||||
OSPlatform: os.platform(),
|
||||
Platform: platform,
|
||||
});
|
||||
})
|
||||
.catch(() => {
|
||||
event.sender.send(Constants.IPC_Get_Platform_Reply, {
|
||||
data: platform,
|
||||
OSPlatform: os.platform(),
|
||||
Platform: platform,
|
||||
});
|
||||
});
|
||||
} else {
|
||||
event.sender.send(Constants.IPC_Get_Platform_Reply, {
|
||||
data: platform,
|
||||
OSPlatform: os.platform(),
|
||||
Platform: platform,
|
||||
});
|
||||
}
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user