still figuring out how to handle default note name...

This commit is contained in:
Ryan Peters
2023-08-04 18:26:22 -04:00
parent e89f9f74fe
commit 41de9e60c4
5 changed files with 27 additions and 6 deletions

View File

@ -1,4 +1,4 @@
const noteName = document.location.pathname.substring(1);
let noteName = '';//document.location.pathname.substring(1);
let connection = new signalR.HubConnectionBuilder()
.withAutomaticReconnect()
@ -58,7 +58,7 @@ $(function () {
// update content after reconnected
connection.onreconnected(function() {
$.get(`api/note?noteName=${noteName}`, function(content) {
$.get(`api/note/${noteName}`, function(content) {
$textarea.val(content);
showToast('#update-indicator');
console.log('Refreshed after disconnect');