use req.user._id

This commit is contained in:
SrGooglo 2023-05-16 19:42:51 +00:00
parent 5be18d916d
commit 332c60773d

View File

@ -10,7 +10,7 @@ export default {
select: ["message", "attachments", "type", "data", "timestamp"],
}, async (req, res) => {
const post = await CreatePost({
user_id: req.user.id,
user_id: req.user._id.toString(),
message: req.selection.message,
timestamp: req.selection.timestamp,
attachments: req.selection.attachments,