Fix route path for update and delete of comments
This commit is contained in:
@ -254,7 +254,7 @@ javascript:
|
|||||||
function deleteComment(commentId, editor, file_id, callback) {
|
function deleteComment(commentId, editor, file_id, callback) {
|
||||||
var jqxhr = $.ajax({
|
var jqxhr = $.ajax({
|
||||||
type: 'DELETE',
|
type: 'DELETE',
|
||||||
url: Routes.comments_path(commentId)
|
url: Routes.comment_path(commentId)
|
||||||
});
|
});
|
||||||
jqxhr.done(function () {
|
jqxhr.done(function () {
|
||||||
setAnnotations(editor, file_id);
|
setAnnotations(editor, file_id);
|
||||||
@ -266,7 +266,7 @@ javascript:
|
|||||||
function updateComment(commentId, text, editor, file_id, callback) {
|
function updateComment(commentId, text, editor, file_id, callback) {
|
||||||
var jqxhr = $.ajax({
|
var jqxhr = $.ajax({
|
||||||
type: 'PATCH',
|
type: 'PATCH',
|
||||||
url: Routes.comments_path(commentId),
|
url: Routes.comment_path(commentId),
|
||||||
data: {
|
data: {
|
||||||
comment: {
|
comment: {
|
||||||
text: text
|
text: text
|
||||||
|
Reference in New Issue
Block a user