Skip to content

Commit

Permalink
Fix post configuration state update on error or success on config html
Browse files Browse the repository at this point in the history
  • Loading branch information
debanjum committed Jun 23, 2023
1 parent 98642e0 commit edabede
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions src/khoj/interface/web/config.html
Original file line number Diff line number Diff line change
Expand Up @@ -106,15 +106,15 @@ <h3 class="card-title">Chat</h3>
console.log('Success:', data);
document.getElementById("status").innerHTML = "Configured successfully!";
document.getElementById("status").style.display = "block";
regenerate.disabled = false;
regenerate.innerHTML = "Configured";
configure.disabled = false;
configure.innerHTML = "⚙️ Configured";
})
.catch((error) => {
console.error('Error:', error);
document.getElementById("status").innerHTML = "Unable to save configuration. Raise issue on Khoj Discord or Github.";
document.getElementById("status").style.display = "block";
regenerate.disabled = false;
regenerate.innerHTML = "Configure";
configure.disabled = false;
configure.innerHTML = "⚙️ Configure";
});
});
</script>
Expand Down

0 comments on commit edabede

Please sign in to comment.