public NoteAllContent ChangeNoteText(string userId, string noteId, INoteContent[] noteContent) { if (_rightsRepository.CanUserEditNote(Guid.Parse(userId), Guid.Parse(noteId))) { Console.WriteLine("aaaa"); return(_noteRepository.ChangeNoteText(Guid.Parse(userId), Guid.Parse(noteId), noteContent)); } else { throw new Exception("No access to edit note.\n"); } }