mirror of
https://github.com/khoaliber/khoj.git
synced 2026-03-04 05:39:06 +00:00
Fix URL to web, desktop settings pages on Desktop application (#903)
Update web and desktop settings URLs on desktop application from previous 'config' path to new 'settings' path
This commit is contained in:
@@ -256,9 +256,9 @@ function pushDataToKhoj (regenerate = false) {
|
||||
.catch(error => {
|
||||
console.error(error);
|
||||
state["completed"] = false;
|
||||
if (error?.response?.status === 429 && (BrowserWindow.getAllWindows().find(win => win.webContents.getURL().includes('config')))) {
|
||||
if (error?.response?.status === 429 && (BrowserWindow.getAllWindows().find(win => win.webContents.getURL().includes('settings')))) {
|
||||
state["error"] = `Looks like you're out of space to sync your files. <a href="https://app.khoj.dev/settings#subscription">Upgrade your plan</a> to unlock more space.`;
|
||||
const win = BrowserWindow.getAllWindows().find(win => win.webContents.getURL().includes('config'));
|
||||
const win = BrowserWindow.getAllWindows().find(win => win.webContents.getURL().includes('settings'));
|
||||
if (win) win.webContents.send('needsSubscription', true);
|
||||
} else if (error?.code === 'ECONNREFUSED') {
|
||||
state["error"] = `Could not connect to Khoj server. Ensure you can connect to it at ${error.address}:${error.port}.`;
|
||||
@@ -270,7 +270,7 @@ function pushDataToKhoj (regenerate = false) {
|
||||
.finally(() => {
|
||||
// Syncing complete
|
||||
syncing = false;
|
||||
const win = BrowserWindow.getAllWindows().find(win => win.webContents.getURL().includes('config'));
|
||||
const win = BrowserWindow.getAllWindows().find(win => win.webContents.getURL().includes('settings'));
|
||||
if (win) {
|
||||
win.webContents.send('update-state', state);
|
||||
}
|
||||
@@ -727,7 +727,7 @@ app.whenReady().then(() => {
|
||||
const contextMenu = Menu.buildFromTemplate([
|
||||
{ label: 'Chat', type: 'normal', click: () => { openWindow('chat.html'); }},
|
||||
{ label: 'Search', type: 'normal', click: () => { openWindow('search.html') }},
|
||||
{ label: 'Configure', type: 'normal', click: () => { openWindow('config.html') }},
|
||||
{ label: 'Configure', type: 'normal', click: () => { openWindow('settings.html') }},
|
||||
{ type: 'separator' },
|
||||
{ label: 'About Khoj', type: 'normal', click: () => { openAboutWindow(); } },
|
||||
{ label: 'Quit', type: 'normal', click: () => { app.quit() } }
|
||||
|
||||
Reference in New Issue
Block a user