MCPcopy Create free account
hub / github.com/Okabe-Rintarou-0/BookStore-Frontend / addBookComment

Function addBookComment

src/service/book.js:71–81  ·  view source on GitHub ↗
(bookId, content)

Source from the content-addressed store, hash-verified

69}
70
71export async function addBookComment(bookId, content) {
72 const url = `${PREFIX}/book/${bookId}/comments`;
73 let res;
74 try {
75 res = await post(url, { 'content': content });
76 } catch (e) {
77 console.log(e);
78 res = DUMMY_RESPONSE;
79 }
80 return res;
81}

Callers 1

handleAddCommentFunction · 0.90

Calls 1

postFunction · 0.90

Tested by

no test coverage detected