Fix Notes and remove Dupe type

This commit is contained in:
CWX
2025-01-25 14:54:00 +00:00
parent 9c3aab4271
commit 91dbfca547
3 changed files with 9 additions and 7 deletions
@@ -23,6 +23,9 @@ public class NoteController(
NoteActionData body,
string sessionId)
{
Note newNote = new Note { Time = body.Note.Time, Text = body.Note.Text };
pmcData.Notes.DataNotes.Add(newNote);
return _eventOutputHolder.GetOutput(sessionId);
}
@@ -38,6 +41,10 @@ public class NoteController(
NoteActionData body,
string sessionId)
{
Note noteToEdit = pmcData.Notes.DataNotes[body.Index!.Value];
noteToEdit.Time = body.Note.Time;
noteToEdit.Text = body.Note.Text;
return _eventOutputHolder.GetOutput(sessionId);
}