fixed even more stuff...trust me you'll love it

This commit is contained in:
xssdoctor 2024-03-31 21:31:45 -04:00
parent fe74efde71
commit 3121730102
3 changed files with 5 additions and 0 deletions

View File

@ -165,6 +165,8 @@ function saveApiKeys(openAIKey, claudeKey) {
}
fs.writeFileSync(envFilePath, envContent.trim());
loadApiKeys();
win.webContents.send("reload-app");
}
function updateOrAddKey(envContent, keyName, keyValue) {

View File

@ -173,6 +173,7 @@ document.addEventListener("DOMContentLoaded", async function () {
() => {
// Reload the app
loadModels();
location.reload();
};
// Submit button click handler
@ -206,6 +207,8 @@ document.addEventListener("DOMContentLoaded", async function () {
configSection.classList.add("hidden");
openaiApiKeyInput.value = "";
claudeApiKeyInput.value = "";
// Reload the models
loadModels();
})
.catch((err) => {
console.error("Error saving API keys:", err);