mirror of
https://github.com/finos/SymphonyElectron.git
synced 2024-11-30 12:43:59 -06:00
Merge pull request #283 from KiranNiranjan/ELECTRON-156
Electron-156 (Updated Protocol Validation)
This commit is contained in:
commit
2855c9b2df
11
js/main.js
11
js/main.js
@ -291,17 +291,14 @@ function getUrlAndCreateMainWindow() {
|
||||
* @param urlFromConfig
|
||||
*/
|
||||
function createWin(urlFromConfig) {
|
||||
let protocol = '';
|
||||
// add https protocol if none found.
|
||||
let parsedUrl = nodeURL.parse(urlFromConfig);
|
||||
|
||||
if (!parsedUrl.protocol) {
|
||||
protocol = 'https';
|
||||
parsedUrl.protocol = 'https:';
|
||||
parsedUrl.slashes = true
|
||||
}
|
||||
let url = nodeURL.format({
|
||||
protocol: protocol,
|
||||
slahes: true,
|
||||
pathname: parsedUrl.href
|
||||
});
|
||||
let url = nodeURL.format(parsedUrl);
|
||||
|
||||
windowMgr.createMainWindow(url);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user