|
@ -193,7 +193,7 @@ export default class ChatController extends SiteController { |
|
|
async postMessageReaction (req, res) { |
|
|
async postMessageReaction (req, res) { |
|
|
const { chat: chatService } = this.dtp.services; |
|
|
const { chat: chatService } = this.dtp.services; |
|
|
try { |
|
|
try { |
|
|
await chatService.checkRoomMember(res.locals.room, req.user); |
|
|
await chatService.checkRoomMember(res.locals.message.channel, req.user); |
|
|
await chatService.toggleMessageReaction(req.user, res.locals.message, req.body); |
|
|
await chatService.toggleMessageReaction(req.user, res.locals.message, req.body); |
|
|
return res.status(200).json({ success: true }); |
|
|
return res.status(200).json({ success: true }); |
|
|
} catch (error) { |
|
|
} catch (error) { |
|
|