mirror of
https://github.com/Troplo/Colubrina.git
synced 2024-11-25 20:49:12 +11:00
Add unpin message
This commit is contained in:
parent
5ee4af70ab
commit
3b46b18ac3
1 changed files with 7 additions and 0 deletions
|
@ -615,6 +615,13 @@ router.post("/:id/pins", auth, async (req, res, next) => {
|
||||||
res.json({
|
res.json({
|
||||||
message: "Message unpinned successfully."
|
message: "Message unpinned successfully."
|
||||||
})
|
})
|
||||||
|
await createMessage(
|
||||||
|
req,
|
||||||
|
"pin",
|
||||||
|
`${req.user.username} unpinned a message from the chat.`,
|
||||||
|
chat,
|
||||||
|
req.user.id
|
||||||
|
)
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
const pin = await Pin.create({
|
const pin = await Pin.create({
|
||||||
|
|
Loading…
Reference in a new issue