Fix route path for update and delete of comments

This commit is contained in:
Sebastian Serth
2021-11-25 10:07:17 +01:00
parent 49c5d5df1f
commit b8bf43eae8

View File

@ -254,7 +254,7 @@ javascript:
function deleteComment(commentId, editor, file_id, callback) {
var jqxhr = $.ajax({
type: 'DELETE',
url: Routes.comments_path(commentId)
url: Routes.comment_path(commentId)
});
jqxhr.done(function () {
setAnnotations(editor, file_id);
@ -266,7 +266,7 @@ javascript:
function updateComment(commentId, text, editor, file_id, callback) {
var jqxhr = $.ajax({
type: 'PATCH',
url: Routes.comments_path(commentId),
url: Routes.comment_path(commentId),
data: {
comment: {
text: text