patch

PATCH 1. PATCH - 이번엔 PATCH 즉, 수정을 해봅시다. - #1. 저번에 입력한 app.js에서 app.get(...) 밑에 다음과 같이 코드를 추가해줍니다. (저번 글 바로가기) app.patch("/wise-sayings/:id", async (req, res) => { // 요청을 보냄 const { id } = req.params; const { author, content } = req.body; const [rows] = await pool.query("SELECT * FROM wise_saying WHERE id = ?", [ id, ]); if (rows.length == 0) { res.status(404).send("not found"); return; } if (row..
NewBean
'patch' 태그의 글 목록