mirror of
https://github.com/zadam/trilium.git
synced 2025-03-01 14:22:32 +01:00
use 127.0.0.1 instead of localhost, #577
This commit is contained in:
parent
d49cae9cea
commit
8624c83108
@ -59,7 +59,7 @@ async function createMainWindow() {
|
||||
mainWindowState.manage(win);
|
||||
|
||||
win.setMenuBarVisibility(false);
|
||||
win.loadURL('http://localhost:' + await port);
|
||||
win.loadURL('http://127.0.0.1:' + await port);
|
||||
win.on('closed', onClosed);
|
||||
|
||||
win.webContents.on('new-window', (e, url) => {
|
||||
@ -74,7 +74,7 @@ async function createMainWindow() {
|
||||
const parsedUrl = url.parse(targetUrl);
|
||||
|
||||
// we still need to allow internal redirects from setup and migration pages
|
||||
if (parsedUrl.hostname !== 'localhost' || (parsedUrl.path && parsedUrl.path !== '/')) {
|
||||
if (parsedUrl.hostname !== 'localhost' || parsedUrl.hostname !== '127.0.0.1' || (parsedUrl.path && parsedUrl.path !== '/')) {
|
||||
ev.preventDefault();
|
||||
}
|
||||
});
|
||||
|
Loading…
x
Reference in New Issue
Block a user